diff --git a/docshell/base/nsDocShell.cpp b/docshell/base/nsDocShell.cpp index bdaf641fb886..3ecd17735a76 100644 --- a/docshell/base/nsDocShell.cpp +++ b/docshell/base/nsDocShell.cpp @@ -153,7 +153,8 @@ NS_IMETHODIMP nsDocShell::GetDocument(nsIDOMDocument** aDocument) NS_ENSURE_TRUE(doc, NS_ERROR_NULL_POINTER); // the result's addref comes from this QueryInterface call - NS_ENSURE_SUCCESS(CallQueryInterface(doc, aDocument), NS_ERROR_FAILURE); + NS_ENSURE_SUCCESS(doc->QueryInterface(NS_GET_IID(nsIDOMDocument), + (void**)aDocument), NS_ERROR_FAILURE); return NS_OK; }