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

Unified Diff: chrome/browser/renderer_host/chrome_resource_dispatcher_host_observer.cc

Issue 7077009: Handle AddPreload/AddPendingPreload on UI thread. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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
« no previous file with comments | « chrome/browser/prerender/prerender_manager_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/chrome_resource_dispatcher_host_observer.cc
===================================================================
--- chrome/browser/renderer_host/chrome_resource_dispatcher_host_observer.cc (revision 86832)
+++ chrome/browser/renderer_host/chrome_resource_dispatcher_host_observer.cc (working copy)
@@ -26,8 +26,6 @@
const content::ResourceContext& resource_context,
const GURL& referrer) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
- bool is_prerendering = prerender_tracker_->IsPrerenderingOnIOThread(
- child_id, route_id);
// Handle a PREFETCH resource type. If prefetch is disabled, squelch the
// request. Otherwise, do a normal request to warm the cache.
@@ -51,15 +49,14 @@
child_id,
route_id,
request_data.url,
- referrer,
- is_prerendering));
+ referrer));
}
// Prerendering or not, this request should be aborted.
return false;
}
// Abort any prerenders that spawn requests that use invalid HTTP methods.
- if (is_prerendering &&
+ if (prerender_tracker_->IsPrerenderingOnIOThread(child_id, route_id) &&
!prerender::PrerenderManager::IsValidHttpMethod(request_data.method)) {
prerender_tracker_->TryCancelOnIOThread(
child_id, route_id,
« no previous file with comments | « chrome/browser/prerender/prerender_manager_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698