From 0b69f4f92899a0c741a2291044f83cc0fd50bbb7 Mon Sep 17 00:00:00 2001 From: Carol Yang Date: Wed, 23 Mar 2022 15:40:11 -0700 Subject: [PATCH] [OTA] Reset instead of cancel when auto-apply is off (#16588) - By the time UpdateDownloaded is called, the download has already completed and there is no need to cancel the download - Reset will make sure the state is transitioned to idle --- examples/ota-requestor-app/linux/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/ota-requestor-app/linux/main.cpp b/examples/ota-requestor-app/linux/main.cpp index df982509d4d8c8..4a3365d4b867f1 100644 --- a/examples/ota-requestor-app/linux/main.cpp +++ b/examples/ota-requestor-app/linux/main.cpp @@ -122,8 +122,8 @@ void CustomOTARequestorDriver::UpdateDownloaded() } else { - // Cancelling will put the state back to idle - gRequestorCore.CancelImageUpdate(); + // Reset to put the state back to idle to allow the next OTA update to occur + gRequestorCore.Reset(); } }