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

Unified Diff: Source/core/dom/Document.cpp

Issue 1044133002: HTMLPreloadScanner should only use valid <base> urls (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: move the check up Created 5 years, 9 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 | « LayoutTests/http/tests/loading/resources/fail.js ('k') | Source/core/html/parser/HTMLPreloadScanner.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Document.cpp
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp
index 646a36b53a65645d7d145b0ce1565c7bb7008fb3..0bc54b1b9749f9fc418cff2509343ec5083135b4 100644
--- a/Source/core/dom/Document.cpp
+++ b/Source/core/dom/Document.cpp
@@ -4192,6 +4192,8 @@ KURL Document::completeURL(const String& url) const
KURL Document::completeURLWithOverride(const String& url, const KURL& baseURLOverride) const
{
+ ASSERT(baseURLOverride.isEmpty() || baseURLOverride.isValid());
+
// Always return a null URL when passed a null string.
// FIXME: Should we change the KURL constructor to have this behavior?
// See also [CSS]StyleSheet::completeURL(const String&)
« no previous file with comments | « LayoutTests/http/tests/loading/resources/fail.js ('k') | Source/core/html/parser/HTMLPreloadScanner.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698