Revert "update_engine: trigger a crash on unrecoverable condition"
This reverts commit 1329fd880962c9441d4ca462e8cda3fbc29049c9.
Reason for revert: https://crbug.com/962730#c18
Original change's description:
> update_engine: trigger a crash on unrecoverable condition
>
> CURLM_INTERNAL_ERROR and CURLM_OUT_OF_MEMORY are two libcurl error codes
> that caller (update_engine) has no way to recover on its own. Reference: https://curl.haxx.se/libcurl/c/libcurl-errors.html
>
> Since those error conditions aren't recoverable and might be responsible
> for the failures to update observed in crbug.com/927039, we exit and let the
> system respawn update_engine to start from a fresh state and recover.
>
> BUG=chromium:962730,chromium:927039
> TEST=unittest
>
> Change-Id: I55946e58e518da5bc5cb0c23690430c6298b8582
> Reviewed-on: https://chromium-review.googlesource.com/1616425
> Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
> Tested-by: Xiaochu Liu <xiaochu@chromium.org>
> Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
> Reviewed-by: Amin Hassani <ahassani@chromium.org>
TBR=senj@chromium.org,norvez@chromium.org,ahassani@chromium.org,xiaochu@chromium.org,chromiumos-cl-exonerator@appspot.gserviceaccount.com
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: chromium:962730, chromium:927039
Change-Id: I3d10173cdacfcd1edf22b4515dce6091e9d3b258
Reviewed-on: https://chromium-review.googlesource.com/c/aosp/platform/system/update_engine/+/1737130
Reviewed-by: Xiaochu Liu <xiaochu@chromium.org>
Reviewed-by: Amin Hassani <ahassani@chromium.org>
Tested-by: Xiaochu Liu <xiaochu@chromium.org>
Commit-Queue: Xiaochu Liu <xiaochu@chromium.org>
diff --git a/libcurl_http_fetcher.cc b/libcurl_http_fetcher.cc
index 6b30eeb..ad823cf 100644
--- a/libcurl_http_fetcher.cc
+++ b/libcurl_http_fetcher.cc
@@ -442,11 +442,7 @@
metrics::CheckResult::kUnset,
metrics::CheckReaction::kUnset,
metrics::DownloadErrorCode::kInternalError);
- // According to https://curl.haxx.se/libcurl/c/libcurl-errors.html:
- // CURLM_INTERNAL_ERROR and CURLM_OUT_OF_MEMORY are two libcurl error codes
- // that caller has no way to recover on its own. Thus, we exit and let the
- // system respawn update_engine to start from a fresh state and recover.
- LOG(FATAL) << "curl_multi_perform is in an unrecoverable error condition: "
+ LOG(ERROR) << "curl_multi_perform is in an unrecoverable error condition: "
<< retcode;
} else if (retcode != CURLM_OK) {
LOG(ERROR) << "curl_multi_perform returns error: " << retcode;