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

Unified Diff: third_party/WebKit/Source/modules/worklet/Worklet.cpp

Issue 2093603002: Wrap non-GCed raw pointer parameters of WTF::bind with WTF::unretained (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@unretained_wrapper
Patch Set: rebase 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/modules/worklet/Worklet.cpp
diff --git a/third_party/WebKit/Source/modules/worklet/Worklet.cpp b/third_party/WebKit/Source/modules/worklet/Worklet.cpp
index 49f93e5ec096f4c5dbea9910324898ef402cf5e8..54993701b26d3318a46beafde5caadf43c95419a 100644
--- a/third_party/WebKit/Source/modules/worklet/Worklet.cpp
+++ b/third_party/WebKit/Source/modules/worklet/Worklet.cpp
@@ -42,8 +42,8 @@ ScriptPromise Worklet::import(ScriptState* scriptState, const String& url)
m_scriptLoaders.append(WorkerScriptLoader::create());
m_scriptLoaders.last()->loadAsynchronously(*getExecutionContext(), scriptURL, DenyCrossOriginRequests,
getExecutionContext()->securityContext().addressSpace(),
- bind(&Worklet::onResponse, wrapPersistent(this), m_scriptLoaders.last().get()),
- bind(&Worklet::onFinished, wrapPersistent(this), m_scriptLoaders.last().get(), wrapPersistent(resolver)));
+ bind(&Worklet::onResponse, wrapPersistent(this), WTF::unretained(m_scriptLoaders.last().get())),
+ bind(&Worklet::onFinished, wrapPersistent(this), WTF::unretained(m_scriptLoaders.last().get()), wrapPersistent(resolver)));
return promise;
}

Powered by Google App Engine
This is Rietveld 408576698