From 8b33d97cdb8a4c9f92f35510fd11cff7724fd105 Mon Sep 17 00:00:00 2001 From: guruchandru Date: Wed, 14 Feb 2024 16:04:44 +0530 Subject: [PATCH 1/2] Removing POST-NONE for FR --- src/webcfg_multipart.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/webcfg_multipart.c b/src/webcfg_multipart.c index a1457a2f..86ffdfd6 100644 --- a/src/webcfg_multipart.c +++ b/src/webcfg_multipart.c @@ -1410,13 +1410,7 @@ void derive_root_doc_version_string(char **rootVersion, uint32_t *root_ver, int if(db_root_string !=NULL) { - if((strcmp(db_root_string,"POST-NONE")==0) && (strcmp(g_RebootReason,FW_UPGRADE_REBOOT_REASON)!=0) && (strcmp(g_RebootReason,FORCED_FW_UPGRADE_REBOOT_REASON)!=0) && (strcmp(g_RebootReason,FACTORY_RESET_REBOOT_REASON)!=0)) - { - *rootVersion = strdup("NONE-REBOOT"); - WEBCFG_FREE(db_root_string); - return; - } - else if(status == 404 && ((strcmp(db_root_string, "NONE") == 0) || (strcmp(db_root_string, "NONE-MIGRATION") == 0) || (strcmp(db_root_string, "NONE-REBOOT") == 0))) + if(status == 404 && ((strcmp(db_root_string, "NONE") == 0) || (strcmp(db_root_string, "NONE-MIGRATION") == 0) || (strcmp(db_root_string, "NONE-REBOOT") == 0))) { *rootVersion = strdup("POST-NONE"); WEBCFG_FREE(db_root_string); From 0188393a63c7f11ba6036339a5b25979d2eacf05 Mon Sep 17 00:00:00 2001 From: Rangaiah Date: Fri, 23 Feb 2024 12:02:18 +0530 Subject: [PATCH 2/2] Added Post none retain header --- src/webcfg_multipart.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/webcfg_multipart.c b/src/webcfg_multipart.c index 86ffdfd6..fbdef6e1 100644 --- a/src/webcfg_multipart.c +++ b/src/webcfg_multipart.c @@ -1589,6 +1589,8 @@ void createCurlHeader( struct curl_slist *list, struct curl_slist **header_list, list = curl_slist_append(list, version_header); WEBCFG_FREE(version_header); } + WebcfgInfo("Post none retain header formed POST-NONE-RETAIN: true\n"); + list = curl_slist_append(list, "POST-NONE-RETAIN: true"); } list = curl_slist_append(list, "Accept: application/msgpack");