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

Unified Diff: third_party/WebKit/Source/core/css/CSSImageValue.cpp

Issue 2130673002: Avoid invoking ResourceFetcher::cachedResource() with a null URL (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: semicolon Created 4 years, 5 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 | « third_party/WebKit/LayoutTests/tables/invalid-background-url-crash.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/CSSImageValue.cpp
diff --git a/third_party/WebKit/Source/core/css/CSSImageValue.cpp b/third_party/WebKit/Source/core/css/CSSImageValue.cpp
index 076639a9d0d09a4e8429195090b191b9dc4f39b6..074de6916f273e87ef2abf6ba2258986d2ba3675 100644
--- a/third_party/WebKit/Source/core/css/CSSImageValue.cpp
+++ b/third_party/WebKit/Source/core/css/CSSImageValue.cpp
@@ -80,7 +80,7 @@ StyleImage* CSSImageValue::cacheImage(Document* document, CrossOriginAttributeVa
void CSSImageValue::restoreCachedResourceIfNeeded(Document& document) const
{
- if (m_isCachePending || !m_cachedImage || !document.fetcher())
+ if (m_isCachePending || !m_cachedImage || !document.fetcher() || m_absoluteURL.isNull())
return;
if (document.fetcher()->cachedResource(KURL(ParsedURLString, m_absoluteURL)))
return;
« no previous file with comments | « third_party/WebKit/LayoutTests/tables/invalid-background-url-crash.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698