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

Unified Diff: net/url_request/url_request.cc

Issue 171099: Merge r21417 to 172.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/branches/172/src/
Patch Set: '' Created 11 years, 4 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
« no previous file with comments | « net/url_request/url_request.h ('k') | net/url_request/url_request_job.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/url_request.cc
===================================================================
--- net/url_request/url_request.cc (revision 23600)
+++ net/url_request/url_request.cc (working copy)
@@ -250,6 +250,7 @@
job_->SetUpload(upload_.get());
is_pending_ = true;
+
response_info_.request_time = Time::Now();
response_info_.was_cached = false;
@@ -319,6 +320,12 @@
return job_->Read(dest, dest_size, bytes_read);
}
+void URLRequest::FollowDeferredRedirect() {
+ DCHECK(job_);
+
+ job_->FollowDeferredRedirect();
+}
+
void URLRequest::SetAuth(const wstring& username, const wstring& password) {
DCHECK(job_);
DCHECK(job_->NeedsAuth());
@@ -340,6 +347,7 @@
}
void URLRequest::OrphanJob() {
+ job_->Kill();
job_->DetachRequest(); // ensures that the job will not call us again
job_ = NULL;
}
@@ -380,7 +388,6 @@
}
url_ = location;
upload_ = NULL;
- status_ = URLRequestStatus();
--redirect_limit_;
if (strip_post_specific_headers) {
@@ -399,8 +406,10 @@
final_upload_progress_ = job_->GetUploadProgress();
}
+ job_->Kill();
OrphanJob();
+ status_ = URLRequestStatus();
is_pending_ = false;
Start();
return net::OK;
« no previous file with comments | « net/url_request/url_request.h ('k') | net/url_request/url_request_job.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698