Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v7

- name: Install Arduino IDE
run: |
Expand Down
6 changes: 4 additions & 2 deletions cores/arduino/WString.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -334,14 +334,16 @@ unsigned char String::concat(unsigned long num)

unsigned char String::concat(float num)
{
char buf[20];
static size_t const FLOAT_BUF_SIZE = (FLT_MAX_10_EXP + 1) + 2 /* FIXED DECIMAL PLACES */ + 1 /* '-' */ + 1 /* '.' */ + 1 /* '\0' */;
char buf[FLOAT_BUF_SIZE];
char* string = dtostrf(num, 4, 2, buf);
return concat(string, strlen(string));
}

unsigned char String::concat(double num)
{
char buf[20];
static size_t const DOUBLE_BUF_SIZE = (DBL_MAX_10_EXP + 1) + 2 /* FIXED DECIMAL PLACES */ + 1 /* '-' */ + 1 /* '.' */ + 1 /* '\0' */;
char buf[DOUBLE_BUF_SIZE];
char* string = dtostrf(num, 4, 2, buf);
return concat(string, strlen(string));
}
Expand Down
2 changes: 1 addition & 1 deletion platform.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# https://arduino.github.io/arduino-cli/latest/platform-specification/

name=XInput AVR Boards
version=1.0.6
version=1.0.7

# AVR compile variables
# ---------------------
Expand Down