This commit is contained in:
CaCO3
2025-02-25 00:22:47 +01:00
parent a413d0228e
commit 1ceb47fbc7

View File

@@ -85,6 +85,10 @@ void task_do_Update_ZIP(void *pvParameter)
outHtmlOld = "/sdcard/html_old"; outHtmlOld = "/sdcard/html_old";
outbin = "/sdcard/firmware"; outbin = "/sdcard/firmware";
/* Remove the old and tmp html folder in case they still exist */
removeFolder(outHtmlTmp.c_str(), TAG);
removeFolder(outHtmlOld.c_str(), TAG);
/* Extract the ZIP file. The content of the html folder gets extracted to the temporar folder html-temp. */ /* Extract the ZIP file. The content of the html folder gets extracted to the temporar folder html-temp. */
LogFile.WriteToFile(ESP_LOG_INFO, TAG, "Extracting ZIP file " + _file_name_update + "..."); LogFile.WriteToFile(ESP_LOG_INFO, TAG, "Extracting ZIP file " + _file_name_update + "...");
retfirmware = unzip_new(_file_name_update, outHtmlTmp+"/", outHtml+"/", outbin+"/", "/sdcard/", initial_setup); retfirmware = unzip_new(_file_name_update, outHtmlTmp+"/", outHtml+"/", outbin+"/", "/sdcard/", initial_setup);