Ensure the right body element is used throughout the method call.
parent
d9b1325e74
commit
0edfc9c9dd
|
@ -659,7 +659,7 @@ ImageDocument::CreateSyntheticDocument()
|
|||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
// Add the image element
|
||||
Element* body = GetBodyElement();
|
||||
RefPtr<Element> body = GetBodyElement();
|
||||
if (!body) {
|
||||
NS_WARNING("no body on image document!");
|
||||
return NS_ERROR_FAILURE;
|
||||
|
|
|
@ -206,7 +206,7 @@ PluginDocument::CreateSyntheticPluginDocument()
|
|||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
// then attach our plugin
|
||||
|
||||
Element* body = GetBodyElement();
|
||||
RefPtr<Element> body = GetBodyElement();
|
||||
if (!body) {
|
||||
NS_WARNING("no body on plugin document!");
|
||||
return NS_ERROR_FAILURE;
|
||||
|
|
|
@ -90,7 +90,7 @@ VideoDocument::CreateSyntheticVideoDocument(nsIChannel* aChannel,
|
|||
nsresult rv = MediaDocument::CreateSyntheticDocument();
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
Element* body = GetBodyElement();
|
||||
RefPtr<Element> body = GetBodyElement();
|
||||
if (!body) {
|
||||
NS_WARNING("no body on video document!");
|
||||
return NS_ERROR_FAILURE;
|
||||
|
|
Loading…
Reference in New Issue