Bug 516186 - Make late charset switch in HTML5 not trigger assertions. r=bnewman.

This commit is contained in:
Henri Sivonen
2009-10-21 15:12:50 +03:00
parent 875857fc6b
commit 605423c728
6 changed files with 72 additions and 9 deletions

View File

@@ -694,3 +694,11 @@ nsHtml5Parser::InitializeDocWriteParserState(nsAHtml5TreeBuilderState* aState)
mLastWasCR = PR_FALSE;
mReturnToStreamParserPermitted = PR_TRUE;
}
void
nsHtml5Parser::ContinueAfterFailedCharsetSwitch()
{
NS_PRECONDITION(mStreamParser,
"Tried to continue after failed charset switch without a stream parser");
mStreamParser->ContinueAfterFailedCharsetSwitch();
}