fix bug 9032, check for null crash

This commit is contained in:
saari@netscape.com
1999-07-04 02:43:58 +00:00
parent 238f37058c
commit f0330c4efe
+3
View File
@@ -1895,6 +1895,9 @@ nsWebShellWindow::HandleUnknownContentType(nsIDocumentLoader* loader,
//----------------------------------------
nsCOMPtr<nsIDOMNode> nsWebShellWindow::FindNamedDOMNode(const nsString &aName, nsIDOMNode * aParent, PRInt32 & aCount, PRInt32 aEndCount)
{
if(!aParent)
return nsnull;
nsCOMPtr<nsIDOMNode> node;
aParent->GetFirstChild(getter_AddRefs(node));
while (node) {