Bug 721313 - Do not run normal parse end code when parsing a full document from string. r=smaug.

This commit is contained in:
Henri Sivonen 2012-01-26 15:59:22 +02:00
parent ce2ca64e46
commit 38e003626d
3 changed files with 7 additions and 2 deletions

View File

@ -136,10 +136,12 @@ nsHtml5TreeOpExecutor::DidBuildModel(bool aTerminated)
}
}
if (!mRunsToCompletion) {
GetParser()->DropStreamParser();
if (mRunsToCompletion) {
return NS_OK;
}
GetParser()->DropStreamParser();
// This comes from nsXMLContentSink and nsHTMLContentSink
DidBuildModelImpl(aTerminated);

View File

@ -0,0 +1,2 @@
<!DOCTYPE html>
<script>(new DOMParser()).parseFromString("", "text/html");</script>

View File

@ -49,3 +49,4 @@ load 591330-1.html
load 650501-1.xhtml
load 696651-1.html
load view-source:699347-1.xml
load 721313-1.html