Skip to content

Commit

Permalink
Incorrect delete fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
blazoncek committed Dec 21, 2021
1 parent 8bd716c commit 8462466
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wled00/FX_fcn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ void WS2812FX::restartRuntime() {
}

void WS2812FX::resetSegments() {
for (uint8_t i = 0; i < MAX_NUM_SEGMENTS; i++) if (_segments[i].name) delete _segments[i].name;
for (uint8_t i = 0; i < MAX_NUM_SEGMENTS; i++) if (_segments[i].name) delete[] _segments[i].name;
mainSegment = 0;
memset(_segments, 0, sizeof(_segments));
//memset(_segment_runtimes, 0, sizeof(_segment_runtimes));
Expand Down

0 comments on commit 8462466

Please sign in to comment.