| Index: third_party/WebKit/Source/platform/threading/BackgroundTaskRunner.cpp
|
| diff --git a/third_party/WebKit/Source/platform/threading/BackgroundTaskRunner.cpp b/third_party/WebKit/Source/platform/threading/BackgroundTaskRunner.cpp
|
| index c75e7e8302daeffc9e4c27cf163c493988d3229b..f365bdc3210fbb01ba68bad5f6c3395ba1ad5127 100644
|
| --- a/third_party/WebKit/Source/platform/threading/BackgroundTaskRunner.cpp
|
| +++ b/third_party/WebKit/Source/platform/threading/BackgroundTaskRunner.cpp
|
| @@ -5,13 +5,14 @@
|
| #include "platform/threading/BackgroundTaskRunner.h"
|
|
|
| #include "base/bind.h"
|
| +#include "base/bind_helpers.h"
|
| #include "base/location.h"
|
| #include "base/threading/worker_pool.h"
|
| #include "public/platform/WebTraceLocation.h"
|
|
|
| namespace blink {
|
|
|
| -static void RunBackgroundTask(PassOwnPtr<CrossThreadClosure> closure)
|
| +static void RunBackgroundTask(CrossThreadClosure* closure)
|
| {
|
| (*closure)();
|
| }
|
| @@ -19,7 +20,7 @@ static void RunBackgroundTask(PassOwnPtr<CrossThreadClosure> closure)
|
| void BackgroundTaskRunner::postOnBackgroundThread(const WebTraceLocation& location, PassOwnPtr<CrossThreadClosure> closure, TaskSize taskSize)
|
| {
|
| tracked_objects::Location baseLocation(location.functionName(), location.fileName(), 0, nullptr);
|
| - base::WorkerPool::PostTask(baseLocation, base::Bind(&RunBackgroundTask, closure), taskSize == TaskSizeLongRunningTask);
|
| + base::WorkerPool::PostTask(baseLocation, base::Bind(&RunBackgroundTask, base::Owned(closure.leakPtr())), taskSize == TaskSizeLongRunningTask);
|
| }
|
|
|
| } // namespace blink
|
|
|