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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp

Issue 2049003002: Wrap GCed raw pointer parameters of WTF::bind with Persistent (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert "unretained" part and "disallow pointers" part Created 4 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
Index: third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp b/third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp
index 2661227470ac0759f7b83803a1774adbb0116511..7a55bfa490e6b32f603fa8ce224524a97a4ac91f 100644
--- a/third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/RejectedPromises.cpp
@@ -210,7 +210,7 @@ void RejectedPromises::handlerAdded(v8::PromiseRejectMessage data)
OwnPtr<Message>& message = m_reportedAsErrors.at(i);
if (!message->isCollected() && message->hasPromise(data.GetPromise())) {
message->makePromiseStrong();
- Platform::current()->currentThread()->scheduler()->timerTaskRunner()->postTask(BLINK_FROM_HERE, bind(&RejectedPromises::revokeNow, this, passed(std::move(message))));
+ Platform::current()->currentThread()->scheduler()->timerTaskRunner()->postTask(BLINK_FROM_HERE, bind(&RejectedPromises::revokeNow, RefPtr<RejectedPromises>(this), passed(std::move(message))));
hiroshige 2016/06/15 12:12:39 I think it is better to split this change into a s
tzik 2016/06/21 09:09:04 Done. I split this part into https://codereview.ch
m_reportedAsErrors.remove(i);
return;
}

Powered by Google App Engine
This is Rietveld 408576698