Merge "[Feature][ZXW-225] Remove synchronization function from lynq fota backup"
diff --git a/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-fota-backup/files/lynq-fota-backup.cpp b/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-fota-backup/files/lynq-fota-backup.cpp
index 84a727b..2c4f1e0 100755
--- a/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-fota-backup/files/lynq-fota-backup.cpp
+++ b/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-fota-backup/files/lynq-fota-backup.cpp
@@ -48,21 +48,16 @@
return -1;
}
-
+
+ //read fota upgrade flag, 0 :upgrade failed, 1:upgrade success
fread(&sync_flag,sizeof(int),1,fp);
-
+
if(sync_flag == FOTA_SYNC_FLAG)
{
- ret = lynq_sync_system();
- if(ret != 0)
- {
- printf("sync faild\n");
- fclose(fp);
- }
- system("rm -rf /mnt/userdata/.back_up_flag");
-
+ printf("upgrade flag is success ");
+ return 0;
}
- else if(sync_flag != FOTA_SYNC_FLAG)
+ else if(sync_flag != FOTA_SYNC_FLAG)
{
ret = lynq_fota_get_addr_value(tmp_addr);
if(ret != 0)
@@ -86,7 +81,8 @@
}
}
-
+
+
return 0;
}