drop doc reference on CSS loader

This commit is contained in:
peterl%netscape.com 1999-05-26 23:50:26 +00:00
parent 08474e20a1
commit 3cf97be519
2 changed files with 8 additions and 2 deletions

View File

@ -171,7 +171,10 @@ nsHTMLDocument::~nsHTMLDocument()
NS_RELEASE(map);
}
NS_IF_RELEASE(mForms);
NS_IF_RELEASE(mCSSLoader);
if (mCSSLoader) {
mCSSLoader->DropDocumentReference(); // release weak ref
NS_RELEASE(mCSSLoader);
}
// XXX don't bother doing this until the dll is unloaded???
// nsHTMLAtoms::ReleaseAtoms();

View File

@ -171,7 +171,10 @@ nsHTMLDocument::~nsHTMLDocument()
NS_RELEASE(map);
}
NS_IF_RELEASE(mForms);
NS_IF_RELEASE(mCSSLoader);
if (mCSSLoader) {
mCSSLoader->DropDocumentReference(); // release weak ref
NS_RELEASE(mCSSLoader);
}
// XXX don't bother doing this until the dll is unloaded???
// nsHTMLAtoms::ReleaseAtoms();