| Index: content/child/background_sync/background_sync_provider_thread_proxy.cc
|
| diff --git a/content/child/background_sync/background_sync_provider_thread_proxy.cc b/content/child/background_sync/background_sync_provider_thread_proxy.cc
|
| index 1937cf3e0ae750773c71bc6804da22dc729c0ef6..90584bfc8380a6d31a2280ddd33303e83e52439a 100644
|
| --- a/content/child/background_sync/background_sync_provider_thread_proxy.cc
|
| +++ b/content/child/background_sync/background_sync_provider_thread_proxy.cc
|
| @@ -106,8 +106,10 @@ void BackgroundSyncProviderThreadProxy::unregisterBackgroundSync(
|
| main_thread_task_runner_->PostTask(
|
| FROM_HERE,
|
| base::Bind(&BackgroundSyncProvider::unregisterBackgroundSync,
|
| - base::Unretained(sync_provider_), periodicity, id, tag,
|
| - service_worker_registration,
|
| + base::Unretained(sync_provider_), periodicity, id,
|
| + // We cast WebString to string16 before crossing threads
|
| + // for thread-safety.
|
| + static_cast<base::string16>(tag), service_worker_registration,
|
| new CallbackThreadAdapter<bool*, blink::WebSyncError*>(
|
| make_scoped_ptr(callbacks),
|
| WorkerTaskRunner::Instance()->CurrentWorkerId())));
|
| @@ -123,8 +125,10 @@ void BackgroundSyncProviderThreadProxy::getRegistration(
|
| main_thread_task_runner_->PostTask(
|
| FROM_HERE,
|
| base::Bind(&BackgroundSyncProvider::getRegistration,
|
| - base::Unretained(sync_provider_), periodicity, tag,
|
| - service_worker_registration,
|
| + base::Unretained(sync_provider_), periodicity,
|
| + // We cast WebString to string16 before crossing threads
|
| + // for thread-safety.
|
| + static_cast<base::string16>(tag), service_worker_registration,
|
| new CallbackThreadAdapter<blink::WebSyncRegistration*,
|
| blink::WebSyncError*>(
|
| make_scoped_ptr(callbacks),
|
|
|