Skip to content

Commit

Permalink
Increase QL buffer to allow unicode characters
Browse files Browse the repository at this point in the history
  • Loading branch information
Aircoookie committed Nov 26, 2022
1 parent 78e9f5b commit 713bf66
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wled00/presets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ static volatile byte presetToApply = 0;
static volatile byte callModeToApply = 0;
static volatile byte presetToSave = 0;
static volatile int8_t saveLedmap = -1;
static char quickLoad[3];
static char quickLoad[9];
static char saveName[33];
static bool includeBri = true, segBounds = true, selectedOnly = false, playlistSave = false;;

Expand Down Expand Up @@ -199,7 +199,7 @@ void savePreset(byte index, const char* pname, JsonObject sObj)

presetToSave = index;
playlistSave = false;
if (sObj[F("ql")].is<const char*>()) strlcpy(quickLoad, sObj[F("ql")].as<const char*>(), 3); // only 2 chars for QL
if (sObj[F("ql")].is<const char*>()) strlcpy(quickLoad, sObj[F("ql")].as<const char*>(), 9); // client limits QL to 2 chars, buffer for 8 bytes to allow unicode
sObj.remove("v");
sObj.remove("time");
sObj.remove(F("error"));
Expand Down

0 comments on commit 713bf66

Please sign in to comment.