Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(123)

Unified Diff: Source/WebCore/bindings/ScriptControllerBase.cpp

Issue 7946004: Merge 94820 - REGRESSION (r66874): Missing RefPtr in ScriptController (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/874/
Patch Set: Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/bindings/ScriptControllerBase.cpp
===================================================================
--- Source/WebCore/bindings/ScriptControllerBase.cpp (revision 95419)
+++ Source/WebCore/bindings/ScriptControllerBase.cpp (working copy)
@@ -67,6 +67,8 @@
bool wasInExecuteScript = m_inExecuteScript;
m_inExecuteScript = true;
+ RefPtr<Frame> protect(m_frame); // Script execution can destroy the frame, and thus the ScriptController.
+
ScriptValue result = evaluate(sourceCode);
if (!wasInExecuteScript) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698