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

Unified Diff: Source/bindings/core/v8/custom/V8MessageEventCustom.cpp

Issue 1153613007: bindings: Use CreateDataProperty() instead of ForceSet() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 7 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/bindings/core/v8/custom/V8MessageEventCustom.cpp
diff --git a/Source/bindings/core/v8/custom/V8MessageEventCustom.cpp b/Source/bindings/core/v8/custom/V8MessageEventCustom.cpp
index 0aa627841998361caebd724614aa0d84160467e3..d5908be8888123b8909a3a39492a6359c1d89f74 100644
--- a/Source/bindings/core/v8/custom/V8MessageEventCustom.cpp
+++ b/Source/bindings/core/v8/custom/V8MessageEventCustom.cpp
@@ -98,6 +98,8 @@ void V8MessageEvent::dataAttributeGetterCustom(const v8::PropertyCallbackInfo<v8
// Overwrite the data attribute so it returns the cached result in future invocations.
// This custom getter handler will not be called again.
+ // TODO(bashi): Use CreateDataProperty() instead of ForceSet().
+ // http://crbug.com/475206
v8::PropertyAttribute dataAttr = static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly);
if (!v8CallBoolean(info.Holder()->ForceSet(info.GetIsolate()->GetCurrentContext(), v8AtomicString(info.GetIsolate(), "data"), result, dataAttr))) {
v8SetReturnValue(info, v8::Null(info.GetIsolate()));

Powered by Google App Engine
This is Rietveld 408576698