summaryrefslogtreecommitdiff
path: root/parser
diff options
context:
space:
mode:
Diffstat (limited to 'parser')
-rw-r--r--parser/html/nsHtml5TreeBuilderCppSupplement.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/parser/html/nsHtml5TreeBuilderCppSupplement.h b/parser/html/nsHtml5TreeBuilderCppSupplement.h
index aa6767e427..96b69e4b1a 100644
--- a/parser/html/nsHtml5TreeBuilderCppSupplement.h
+++ b/parser/html/nsHtml5TreeBuilderCppSupplement.h
@@ -945,6 +945,9 @@ nsHtml5TreeBuilder::elementPopped(int32_t aNamespace, nsIAtom* aName, nsIContent
}
if (aNamespace == kNameSpaceID_SVG) {
if (aName == nsHtml5Atoms::svg) {
+ if (!scriptingEnabled || mPreventScriptExecution) {
+ return;
+ }
if (mBuilder) {
nsHtml5TreeOperation::SvgLoad(static_cast<nsIContent*>(aElement));
return;