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

Unified Diff: Source/modules/compositorworker/CompositorWorkerGlobalScope.cpp

Issue 1041053005: Oilpan: fix WorkerThreadStartupData finalization handling. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: add comment clarifying use of CrossThreadPersistent<> Created 5 years, 9 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/modules/compositorworker/CompositorWorkerGlobalScope.cpp
diff --git a/Source/modules/compositorworker/CompositorWorkerGlobalScope.cpp b/Source/modules/compositorworker/CompositorWorkerGlobalScope.cpp
index d4c47c0d724d78d63995f0db74d84815b93c1600..84b1880780e9466b8797f554ec1d216bfd2085ef 100644
--- a/Source/modules/compositorworker/CompositorWorkerGlobalScope.cpp
+++ b/Source/modules/compositorworker/CompositorWorkerGlobalScope.cpp
@@ -13,8 +13,10 @@
namespace blink {
-PassRefPtrWillBeRawPtr<CompositorWorkerGlobalScope> CompositorWorkerGlobalScope::create(CompositorWorkerThread* thread, PassOwnPtrWillBeRawPtr<WorkerThreadStartupData> startupData, double timeOrigin)
+PassRefPtrWillBeRawPtr<CompositorWorkerGlobalScope> CompositorWorkerGlobalScope::create(CompositorWorkerThread* thread, PassOwnPtr<WorkerThreadStartupData> startupData, double timeOrigin)
{
+ // Note: startupData is finalized on return. After the relevant parts has been
+ // passed along to the created 'context'.
RefPtrWillBeRawPtr<CompositorWorkerGlobalScope> context = adoptRefWillBeNoop(new CompositorWorkerGlobalScope(startupData->m_scriptURL, startupData->m_userAgent, thread, timeOrigin, startupData->m_starterOrigin, startupData->m_workerClients.release()));
context->applyContentSecurityPolicyFromString(startupData->m_contentSecurityPolicy, startupData->m_contentSecurityPolicyType);
return context.release();

Powered by Google App Engine
This is Rietveld 408576698