diff --git a/mozilla/xpfe/appshell/src/nsWebShellWindow.cpp b/mozilla/xpfe/appshell/src/nsWebShellWindow.cpp index 266da198b47..45831c83722 100644 --- a/mozilla/xpfe/appshell/src/nsWebShellWindow.cpp +++ b/mozilla/xpfe/appshell/src/nsWebShellWindow.cpp @@ -1006,8 +1006,9 @@ nsWebShellWindow::CreatePopup(nsIDOMElement* aElement, nsIDOMElement* aPopupCont if (parentDocument == nsnull) return NS_ERROR_FAILURE; + nsCOMPtr popupContent = do_QueryInterface(aPopupContent); nsCOMPtr popupDocument; - if (NS_FAILED(rv = parentDocument->CreatePopupDocument(aPopupContent, getter_AddRefs(popupDocument)))) { + if (NS_FAILED(rv = parentDocument->CreatePopupDocument(popupContent, getter_AddRefs(popupDocument)))) { NS_ERROR("Unable to create the child popup document."); return rv; }