зеркало из https://github.com/mozilla/gecko-dev.git
fixed a few infinite loops in new DTD code
This commit is contained in:
Родитель
d33b347700
Коммит
0def007cba
|
@ -757,15 +757,14 @@ nsresult CNavDTD::HandleStartToken(CToken* aToken) {
|
|||
}
|
||||
break;
|
||||
|
||||
case eHTMLTag_link:
|
||||
case eHTMLTag_base:
|
||||
case eHTMLTag_meta:
|
||||
case eHTMLTag_link:
|
||||
{
|
||||
result=OpenHead(attrNode);
|
||||
if(NS_OK==result)
|
||||
result=AddLeaf(attrNode);
|
||||
if(NS_OK==result)
|
||||
result=CloseHead(attrNode);
|
||||
result=CloseHead(attrNode);
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -2628,7 +2627,7 @@ nsresult CNavDTD::CloseTopmostContainer(){
|
|||
* 2nd, pass this message on to the sink.
|
||||
* @update gess4/6/98
|
||||
* @param aNode -- next node to be added to model
|
||||
* @return TRUE if ok, FALSE if error
|
||||
* @return error code; 0 means OK
|
||||
*/
|
||||
nsresult CNavDTD::AddLeaf(const nsIParserNode& aNode){
|
||||
nsresult result=mSink->AddLeaf(aNode);
|
||||
|
|
|
@ -617,6 +617,7 @@ protected:
|
|||
|
||||
PRBool mHasOpenForm;
|
||||
PRBool mHasOpenMap;
|
||||
PRBool mHasOpenHead;
|
||||
nsDeque mTokenDeque;
|
||||
nsString mFilename;
|
||||
nsIDTDDebug* mDTDDebug;
|
||||
|
|
|
@ -757,15 +757,14 @@ nsresult CNavDTD::HandleStartToken(CToken* aToken) {
|
|||
}
|
||||
break;
|
||||
|
||||
case eHTMLTag_link:
|
||||
case eHTMLTag_base:
|
||||
case eHTMLTag_meta:
|
||||
case eHTMLTag_link:
|
||||
{
|
||||
result=OpenHead(attrNode);
|
||||
if(NS_OK==result)
|
||||
result=AddLeaf(attrNode);
|
||||
if(NS_OK==result)
|
||||
result=CloseHead(attrNode);
|
||||
result=CloseHead(attrNode);
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -2628,7 +2627,7 @@ nsresult CNavDTD::CloseTopmostContainer(){
|
|||
* 2nd, pass this message on to the sink.
|
||||
* @update gess4/6/98
|
||||
* @param aNode -- next node to be added to model
|
||||
* @return TRUE if ok, FALSE if error
|
||||
* @return error code; 0 means OK
|
||||
*/
|
||||
nsresult CNavDTD::AddLeaf(const nsIParserNode& aNode){
|
||||
nsresult result=mSink->AddLeaf(aNode);
|
||||
|
|
|
@ -617,6 +617,7 @@ protected:
|
|||
|
||||
PRBool mHasOpenForm;
|
||||
PRBool mHasOpenMap;
|
||||
PRBool mHasOpenHead;
|
||||
nsDeque mTokenDeque;
|
||||
nsString mFilename;
|
||||
nsIDTDDebug* mDTDDebug;
|
||||
|
|
Загрузка…
Ссылка в новой задаче