Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(797)

Unified Diff: net/url_request/url_fetcher_core.cc

Issue 1164823002: Remove URLRequestStatus mutators and introduce FromError. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/url_request/url_fetcher_core.cc
diff --git a/net/url_request/url_fetcher_core.cc b/net/url_request/url_fetcher_core.cc
index d34f20f4d0919a1ad58108060c6e2f7cd5f3dcad..027991100532cb50d44c93a5d87c1a6ee789ca04 100644
--- a/net/url_request/url_fetcher_core.cc
+++ b/net/url_request/url_fetcher_core.cc
@@ -668,8 +668,7 @@ void URLFetcherCore::CancelURLRequest(int error) {
// URLRequestJob::NotifyDone(). But, because the request was released
// immediately after being canceled, the request could not call
// OnReadCompleted() which overwrites |status_| with the error status.
- status_.set_status(URLRequestStatus::CANCELED);
- status_.set_error(error);
+ status_ = URLRequestStatus(URLRequestStatus::CANCELED, error);
// Release the reference to the request context. There could be multiple
// references to URLFetcher::Core at this point so it may take a while to

Powered by Google App Engine
This is Rietveld 408576698