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

Unified Diff: Source/bindings/templates/attributes.cpp

Issue 419163004: Add HandleScopes and ScriptForbiddenScope::AllowUserAgentScript to private scripts (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | « Source/bindings/scripts/v8_methods.py ('k') | Source/bindings/templates/methods.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/templates/attributes.cpp
diff --git a/Source/bindings/templates/attributes.cpp b/Source/bindings/templates/attributes.cpp
index e870db8d3ebba3a3228ec98feb5f6baafc03ffcf..36e963f9004ad38d0522dc42b7cc11f0f9e90a87 100644
--- a/Source/bindings/templates/attributes.cpp
+++ b/Source/bindings/templates/attributes.cpp
@@ -345,6 +345,8 @@ bool {{v8_class}}::{{attribute.name}}AttributeGetterImplementedInPrivateScript(L
{
if (!frame)
return false;
+ v8::HandleScope handleScope(toIsolate(frame));
+ ScriptForbiddenScope::AllowUserAgentScript script;
v8::Handle<v8::Context> context = toV8Context(frame, DOMWrapperWorld::privateScriptIsolatedWorld());
if (context.IsEmpty())
return false;
@@ -379,6 +381,8 @@ bool {{v8_class}}::{{attribute.name}}AttributeSetterImplementedInPrivateScript(L
{
if (!frame)
return false;
+ v8::HandleScope handleScope(toIsolate(frame));
+ ScriptForbiddenScope::AllowUserAgentScript script;
v8::Handle<v8::Context> context = toV8Context(frame, DOMWrapperWorld::privateScriptIsolatedWorld());
if (context.IsEmpty())
return false;
« no previous file with comments | « Source/bindings/scripts/v8_methods.py ('k') | Source/bindings/templates/methods.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698