bug 256731: unclosed userdefined tags inside phrasal tags cause the phrasal tags to be unable to close. r=rbs sr=bzbarsky

This commit is contained in:
mrbkap%gmail.com 2004-10-25 23:33:04 +00:00
parent 74d7da1acd
commit e4da3fc5b4

View File

@ -2069,8 +2069,12 @@ eHTMLTags nsHTMLElement::GetCloseTargetForEndTag(nsDTDContext& aContext,PRInt32
if(IsMemberOf(kPhrase)){
while((--theIndex>=anIndex) && (eHTMLTag_unknown==result)){
eHTMLTags theTag=aContext.TagAt(theIndex);
if(theTag!=mTagID) {
eHTMLTags theTag = aContext.TagAt(theIndex);
if(theTag != mTagID) {
// Allow phrasals to close userdefined tags. bug 256731
if(eHTMLTag_userdefined == theTag) {
continue; // We can close this.
}
//fixes a derivative of bug 22842...
if(CanContainType(kBlock)) { //INS/DEL can contain blocks.