Index: third_party/WebKit/Source/core/html/MediaDocument.cpp |
diff --git a/third_party/WebKit/Source/core/html/MediaDocument.cpp b/third_party/WebKit/Source/core/html/MediaDocument.cpp |
index eec9b699e238c33de79d770fc4f1ffe5046d7e09..0fdef5333ded9d3d2f14be6fe09010aa37650198 100644 |
--- a/third_party/WebKit/Source/core/html/MediaDocument.cpp |
+++ b/third_party/WebKit/Source/core/html/MediaDocument.cpp |
@@ -126,11 +126,9 @@ void MediaDocumentParser::createDocumentStructure() |
{ |
ASSERT(document()); |
HTMLHtmlElement* rootElement = HTMLHtmlElement::create(*document()); |
- rootElement->insertedByParser(); |
document()->appendChild(rootElement); |
+ rootElement->insertedByParser(); |
- document()->frame()->loader().dispatchDocumentElementAvailable(); |
- document()->frame()->loader().runScriptsAtDocumentElementAvailable(); |
if (isDetached()) |
return; // runScriptsAtDocumentElementAvailable can detach the frame. |