119038 - Make sure that WillResume() and WillInterrupt() get called on the sink. This should fix the fast loader assertion. r=heikki, sr=brendan

This commit is contained in:
harishd%netscape.com 2002-01-11 01:26:41 +00:00
Родитель 720ebc13e5
Коммит d90fad4f02
4 изменённых файлов: 8 добавлений и 8 удалений

Просмотреть файл

@ -163,7 +163,7 @@ public:
* @update gess5/18/98 * @update gess5/18/98
* @return ignored * @return ignored
*/ */
NS_IMETHOD WillResumeParse(nsIContentSink* aSink = 0) = 0; NS_IMETHOD WillResumeParse(nsIContentSink* aSink) = 0;
/** /**
* If the parse process gets interrupted, this method is called by * If the parse process gets interrupted, this method is called by
@ -171,7 +171,7 @@ public:
* @update gess5/18/98 * @update gess5/18/98
* @return ignored * @return ignored
*/ */
NS_IMETHOD WillInterruptParse(nsIContentSink* aSink = 0) = 0; NS_IMETHOD WillInterruptParse(nsIContentSink* aSink) = 0;
/** /**
* This method is called to determine whether or not a tag of one * This method is called to determine whether or not a tag of one

Просмотреть файл

@ -1823,7 +1823,7 @@ nsresult nsParser::ResumeParse(PRBool allowIteration, PRBool aIsFinalChunk, PRBo
result=WillBuildModel(mParserContext->mScanner->GetFilename()); result=WillBuildModel(mParserContext->mScanner->GetFilename());
if(mParserContext->mDTD) { if(mParserContext->mDTD) {
mParserContext->mDTD->WillResumeParse(); mParserContext->mDTD->WillResumeParse(mSink);
PRBool theFirstTime=PR_TRUE; PRBool theFirstTime=PR_TRUE;
PRBool theIterationIsOk=(theFirstTime || allowIteration||(!mParserContext->mPrevContext)); PRBool theIterationIsOk=(theFirstTime || allowIteration||(!mParserContext->mPrevContext));
@ -1930,7 +1930,7 @@ nsresult nsParser::ResumeParse(PRBool allowIteration, PRBool aIsFinalChunk, PRBo
if((kEOF==theTokenizerResult) || (result==NS_ERROR_HTMLPARSER_INTERRUPTED)) { if((kEOF==theTokenizerResult) || (result==NS_ERROR_HTMLPARSER_INTERRUPTED)) {
result = (result == NS_ERROR_HTMLPARSER_INTERRUPTED) ? NS_OK : result; result = (result == NS_ERROR_HTMLPARSER_INTERRUPTED) ? NS_OK : result;
if (mParserContext->mDTD) { if (mParserContext->mDTD) {
mParserContext->mDTD->WillInterruptParse(); mParserContext->mDTD->WillInterruptParse(mSink);
} }
} }

Просмотреть файл

@ -163,7 +163,7 @@ public:
* @update gess5/18/98 * @update gess5/18/98
* @return ignored * @return ignored
*/ */
NS_IMETHOD WillResumeParse(nsIContentSink* aSink = 0) = 0; NS_IMETHOD WillResumeParse(nsIContentSink* aSink) = 0;
/** /**
* If the parse process gets interrupted, this method is called by * If the parse process gets interrupted, this method is called by
@ -171,7 +171,7 @@ public:
* @update gess5/18/98 * @update gess5/18/98
* @return ignored * @return ignored
*/ */
NS_IMETHOD WillInterruptParse(nsIContentSink* aSink = 0) = 0; NS_IMETHOD WillInterruptParse(nsIContentSink* aSink) = 0;
/** /**
* This method is called to determine whether or not a tag of one * This method is called to determine whether or not a tag of one

Просмотреть файл

@ -1823,7 +1823,7 @@ nsresult nsParser::ResumeParse(PRBool allowIteration, PRBool aIsFinalChunk, PRBo
result=WillBuildModel(mParserContext->mScanner->GetFilename()); result=WillBuildModel(mParserContext->mScanner->GetFilename());
if(mParserContext->mDTD) { if(mParserContext->mDTD) {
mParserContext->mDTD->WillResumeParse(); mParserContext->mDTD->WillResumeParse(mSink);
PRBool theFirstTime=PR_TRUE; PRBool theFirstTime=PR_TRUE;
PRBool theIterationIsOk=(theFirstTime || allowIteration||(!mParserContext->mPrevContext)); PRBool theIterationIsOk=(theFirstTime || allowIteration||(!mParserContext->mPrevContext));
@ -1930,7 +1930,7 @@ nsresult nsParser::ResumeParse(PRBool allowIteration, PRBool aIsFinalChunk, PRBo
if((kEOF==theTokenizerResult) || (result==NS_ERROR_HTMLPARSER_INTERRUPTED)) { if((kEOF==theTokenizerResult) || (result==NS_ERROR_HTMLPARSER_INTERRUPTED)) {
result = (result == NS_ERROR_HTMLPARSER_INTERRUPTED) ? NS_OK : result; result = (result == NS_ERROR_HTMLPARSER_INTERRUPTED) ? NS_OK : result;
if (mParserContext->mDTD) { if (mParserContext->mDTD) {
mParserContext->mDTD->WillInterruptParse(); mParserContext->mDTD->WillInterruptParse(mSink);
} }
} }