Removed check for the image state being eOTA_ImageState_Unknown
Now when the prvProcessOTAJobMsg and the image state is not the
self_test state, it will always call prvSetImageStateWithReason
being an abort and parse error.
@@ -1481,10 +1481,12 @@ static void prvOTAUpdateTask( void * pvUnused )
( void ) prvResetDevice(); /* Ignore return code since there's nothing we can do if we can't force reset. */
}
}
- else if (OTA_GetImageState() == eOTA_ImageState_Unknown)
+ else
{
- /* If the job context returned NULL and the image state is unknown, then an error
- * occurred parsing the OTA job message. Abort the OTA job with a parse error.
+ /* If the job context returned NULL and the image state is not in the self_test state,
+ * then an error occurred parsing the OTA job message. Abort the OTA job with a parse error.
+ *
+ * If there is a valid job id, then a job status update will be sent.
*/
( void ) prvSetImageStateWithReason( eOTA_ImageState_Aborted, kOTA_Err_JobParserError );
}
