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

Unified Diff: webkit/support/weburl_loader_mock.cc

Issue 17229012: don't let weburl_loader_mock fallback for non-data urls (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: use GURL Created 7 years, 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/support/weburl_loader_mock.cc
diff --git a/webkit/support/weburl_loader_mock.cc b/webkit/support/weburl_loader_mock.cc
index ccdf622a022d664ea0ca18fce0ed0bd527504547..06aff4da960d5828be825dfed1a002c3d855166d 100644
--- a/webkit/support/weburl_loader_mock.cc
+++ b/webkit/support/weburl_loader_mock.cc
@@ -58,6 +58,9 @@ void WebURLLoaderMock::loadSynchronously(const WebKit::WebURLRequest& request,
factory_->LoadSynchronously(request, &response, &error, &data);
return;
}
+ DCHECK(static_cast<const GURL&>(request.url()).SchemeIs("data"))
jamesr 2013/06/20 04:36:21 oh C++. you so silly
+ << "loadSynchronously shouldn't be falling back: "
+ << request.url().spec().data();
using_default_loader_ = true;
default_loader_->loadSynchronously(request, response, error, data);
}
@@ -69,6 +72,9 @@ void WebURLLoaderMock::loadAsynchronously(const WebKit::WebURLRequest& request,
factory_->LoadAsynchronouly(request, this);
return;
}
+ DCHECK(static_cast<const GURL&>(request.url()).SchemeIs("data"))
+ << "loadAsynchronously shouldn't be falling back: "
+ << request.url().spec().data();
using_default_loader_ = true;
default_loader_->loadAsynchronously(request, client);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698