Playlist load bugfix.

serializeConfig() in loop() (prevent crash/hang in web server callback)
This commit is contained in:
Blaz Kristan
2022-09-14 22:28:06 +02:00
parent 8402de601f
commit 799d4f9465
7 changed files with 27 additions and 25 deletions

View File

@@ -607,7 +607,7 @@ void handleSettingsSet(AsyncWebServerRequest *request, byte subPage)
}
}
usermods.readFromConfig(um); // force change of usermod parameters
DEBUG_PRINTLN(F("Done re-init usermods."));
releaseJSONBufferLock();
}
@@ -638,7 +638,7 @@ void handleSettingsSet(AsyncWebServerRequest *request, byte subPage)
#endif
lastEditTime = millis();
if (subPage != 2 && !doReboot) serializeConfig(); //do not save if factory reset or LED settings (which are saved after LED re-init)
if (subPage != 2 && !doReboot) doSerializeConfig = true; //serializeConfig(); //do not save if factory reset or LED settings (which are saved after LED re-init)
if (subPage == 4) alexaInit();
}