Fixed an improper use of NS_RELEASE

This commit is contained in:
kipp%netscape.com 1998-12-08 16:08:44 +00:00
parent a986505b5c
commit 825f4e5f8b
2 changed files with 6 additions and 8 deletions

View File

@ -1290,10 +1290,9 @@ nsGenericElement::AddRef()
NS_IMETHODIMP_(nsrefcnt)
nsGenericElement::Release()
{
nsIContent* content = mContent;
// Release the copy since the macro will null the pointer.
return NS_RELEASE(content);
nsrefcnt rc;
NS_RELEASE2(mContent, rc);
return rc;
}
//----------------------------------------------------------------------

View File

@ -1290,10 +1290,9 @@ nsGenericElement::AddRef()
NS_IMETHODIMP_(nsrefcnt)
nsGenericElement::Release()
{
nsIContent* content = mContent;
// Release the copy since the macro will null the pointer.
return NS_RELEASE(content);
nsrefcnt rc;
NS_RELEASE2(mContent, rc);
return rc;
}
//----------------------------------------------------------------------