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

Unified Diff: chrome/browser/automation/url_request_automation_job.cc

Issue 402107: ChromeFrame's host network stack implementation for IE full tab mode implicit... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month 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 | « no previous file | chrome_frame/urlmon_url_request.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/automation/url_request_automation_job.cc
===================================================================
--- chrome/browser/automation/url_request_automation_job.cc (revision 32803)
+++ chrome/browser/automation/url_request_automation_job.cc (working copy)
@@ -198,20 +198,12 @@
bool URLRequestAutomationJob::IsRedirectResponse(
GURL* location, int* http_status_code) {
- static const int kDefaultHttpRedirectResponseCode = 301;
+ if (!net::HttpResponseHeaders::IsRedirectResponseCode(redirect_status_))
+ return false;
- if (!redirect_url_.empty()) {
- DLOG_IF(ERROR, redirect_status_ == 0) << "Missing redirect status?";
- *http_status_code = redirect_status_ ? redirect_status_ :
- kDefaultHttpRedirectResponseCode;
- *location = GURL(redirect_url_);
- return true;
- } else {
- DCHECK(redirect_status_ == 0)
- << "Unexpectedly have redirect status but no URL";
- }
-
- return false;
+ *http_status_code = redirect_status_;
+ *location = GURL(redirect_url_);
+ return true;
}
bool URLRequestAutomationJob::MayFilterMessage(const IPC::Message& message,
@@ -255,7 +247,7 @@
GURL url_for_cookies =
GURL(redirect_url_.empty() ? request_->url().spec().c_str() :
- redirect_url_.c_str());
+ redirect_url_.c_str());
URLRequestContext* ctx = request_->context();
« no previous file with comments | « no previous file | chrome_frame/urlmon_url_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698