| Index: Source/WebKit/chromium/src/WebFrameImpl.cpp
|
| ===================================================================
|
| --- Source/WebKit/chromium/src/WebFrameImpl.cpp (revision 97088)
|
| +++ Source/WebKit/chromium/src/WebFrameImpl.cpp (working copy)
|
| @@ -2259,6 +2259,8 @@
|
| if (!m_frame->document() || !m_frame->page())
|
| return;
|
|
|
| + RefPtr<Document> ownerDocument(m_frame->document());
|
| +
|
| // Protect privileged pages against bookmarklets and other javascript manipulations.
|
| if (SchemeRegistry::shouldTreatURLSchemeAsNotAllowingJavascriptURLs(m_frame->document()->url().protocol()))
|
| return;
|
| @@ -2271,7 +2273,7 @@
|
| return;
|
|
|
| if (!m_frame->navigationScheduler()->locationChangePending())
|
| - m_frame->document()->loader()->writer()->replaceDocument(scriptResult);
|
| + m_frame->document()->loader()->writer()->replaceDocument(scriptResult, ownerDocument.get());
|
| }
|
|
|
| } // namespace WebKit
|
|
|