bug fix ota destory

This commit is contained in:
ethan.du 2021-05-24 18:33:57 +08:00
parent 843764ccc8
commit 298050e233
1 changed files with 8 additions and 1 deletions

View File

@ -282,7 +282,6 @@ int IOT_OTA_Destroy(void *handle)
}
osc_deinit(h_ota->ch_signal);
ofc_deinit(h_ota->ch_fetch);
ota_lib_md5_deinit(h_ota->md5);
if (NULL != h_ota->url) {
@ -305,6 +304,14 @@ int IOT_OTA_Destroy(void *handle)
HAL_Free(h_ota->download_name);
}
if (NULL != h_ota->current_version) {
HAL_Free(h_ota->current_version);
}
if (NULL != h_ota->taskID) {
HAL_Free(h_ota->taskID);
}
HAL_Free(h_ota);
return SUCCESS_RET;
}