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

Unified Diff: Source/core/svg/SVGDocumentExtensions.cpp

Issue 134263003: Followup fixes for bug 332066. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebased Created 6 years, 11 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/svg/custom/loadevents-async-expected.txt ('k') | Source/core/svg/SVGUseElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGDocumentExtensions.cpp
diff --git a/Source/core/svg/SVGDocumentExtensions.cpp b/Source/core/svg/SVGDocumentExtensions.cpp
index a135845e0365d2258e63751551008e07dd6608ee..c52c15b62109c5696642a25d020e7f05eebfd56d 100644
--- a/Source/core/svg/SVGDocumentExtensions.cpp
+++ b/Source/core/svg/SVGDocumentExtensions.cpp
@@ -120,7 +120,10 @@ void SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements()
SVGSVGElement* outerSVG = (*it).get();
if (!outerSVG->isOutermostSVGSVGElement())
continue;
- outerSVG->sendSVGLoadEventIfPossible();
+
+ // don't dispatch the load event document is not wellformed (for XML/standalone svg)
+ if (outerSVG->document().wellFormed() || !outerSVG->document().isSVGDocument())
+ outerSVG->sendSVGLoadEventIfPossible();
}
}
« no previous file with comments | « LayoutTests/svg/custom/loadevents-async-expected.txt ('k') | Source/core/svg/SVGUseElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698