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

Unified Diff: Source/web/WebDOMError.cpp

Issue 1166793006: bindings: Stop using the given creationContext in public APIs. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 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/web/WebBlob.cpp ('k') | Source/web/WebDOMFileSystem.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/WebDOMError.cpp
diff --git a/Source/web/WebDOMError.cpp b/Source/web/WebDOMError.cpp
index d4a7f907f79447097c42a3385dfb20897aa89131..507738cbf8742a3732a93bf91313e1383bcacc52 100644
--- a/Source/web/WebDOMError.cpp
+++ b/Source/web/WebDOMError.cpp
@@ -67,11 +67,13 @@ WebString WebDOMError::message() const
return m_private->message();
}
-v8::Local<v8::Value> WebDOMError::toV8Value(v8::Local<v8::Object> creationContext, v8::Isolate* isolate)
+v8::Local<v8::Value> WebDOMError::toV8Value(v8::Local<v8::Object> /* creationContext */, v8::Isolate* isolate)
{
+ // We no longer use |creationContext| because it's often misused and points
+ // to a context faked by user script.
if (!m_private.get())
return v8::Local<v8::Value>();
- return toV8(m_private.get(), creationContext, isolate);
+ return toV8(m_private.get(), isolate->GetCurrentContext()->Global(), isolate);
}
WebDOMError::WebDOMError(DOMError* error)
« no previous file with comments | « Source/web/WebBlob.cpp ('k') | Source/web/WebDOMFileSystem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698