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

Unified Diff: Source/WebCore/bindings/v8/V8RecursionScope.h

Issue 9951003: Merge 112161 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1025/
Patch Set: Created 8 years, 9 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
Index: Source/WebCore/bindings/v8/V8RecursionScope.h
===================================================================
--- Source/WebCore/bindings/v8/V8RecursionScope.h (revision 112630)
+++ Source/WebCore/bindings/v8/V8RecursionScope.h (working copy)
@@ -31,17 +31,16 @@
#ifndef V8RecursionScope_h
#define V8RecursionScope_h
+#include "ScriptExecutionContext.h"
#include "V8Binding.h"
namespace WebCore {
-class ScriptExecutionContext;
-
class V8RecursionScope {
WTF_MAKE_NONCOPYABLE(V8RecursionScope);
public:
explicit V8RecursionScope(ScriptExecutionContext* context)
- : m_context(context)
+ : m_isDocumentContext(context && context->isDocument())
{
V8BindingPerIsolateData::current()->incrementRecursionLevel();
}
@@ -49,15 +48,15 @@
~V8RecursionScope()
{
if (!V8BindingPerIsolateData::current()->decrementRecursionLevel())
- didLeaveScriptContext(m_context);
+ didLeaveScriptContext();
}
static int recursionLevel() { return V8BindingPerIsolateData::current()->recursionLevel(); }
private:
- static void didLeaveScriptContext(ScriptExecutionContext*);
+ void didLeaveScriptContext();
- ScriptExecutionContext* m_context;
+ bool m_isDocumentContext;
};
} // namespace WebCore
« no previous file with comments | « LayoutTests/fast/frames/subframe-load-js-url-crash-expected.txt ('k') | Source/WebCore/bindings/v8/V8RecursionScope.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698