| Index: content/renderer/renderer_webkitplatformsupport_impl.cc
|
| diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
|
| index 0d4a9327f7c86aa221c71e6b374d1aeab5e2388f..3e30e1ddee4115f5d13254f35bd9c7aa3441168d 100644
|
| --- a/content/renderer/renderer_webkitplatformsupport_impl.cc
|
| +++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
|
| @@ -19,6 +19,7 @@
|
| #include "content/child/indexed_db/proxy_webidbfactory_impl.h"
|
| #include "content/child/npapi/npobject_util.h"
|
| #include "content/child/quota_dispatcher.h"
|
| +#include "content/child/quota_message_filter.h"
|
| #include "content/child/thread_safe_sender.h"
|
| #include "content/child/webblobregistry_impl.h"
|
| #include "content/child/webmessageportchannel_impl.h"
|
| @@ -241,6 +242,7 @@ RendererWebKitPlatformSupportImpl::RendererWebKitPlatformSupportImpl()
|
| if (ChildThread::current()) {
|
| sync_message_filter_ = ChildThread::current()->sync_message_filter();
|
| thread_safe_sender_ = ChildThread::current()->thread_safe_sender();
|
| + quota_message_filter_ = ChildThread::current()->quota_message_filter();
|
| }
|
| }
|
|
|
| @@ -1148,10 +1150,14 @@ void RendererWebKitPlatformSupportImpl::queryStorageUsageAndQuota(
|
| const WebKit::WebURL& storage_partition,
|
| WebKit::WebStorageQuotaType type,
|
| WebKit::WebStorageQuotaCallbacks* callbacks) {
|
| - ChildThread::current()->quota_dispatcher()->QueryStorageUsageAndQuota(
|
| - storage_partition,
|
| - static_cast<quota::StorageType>(type),
|
| - QuotaDispatcher::CreateWebStorageQuotaCallbacksWrapper(callbacks));
|
| + if (!thread_safe_sender_.get() || !quota_message_filter_.get())
|
| + return;
|
| + QuotaDispatcher::ThreadSpecificInstance(
|
| + thread_safe_sender_.get(),
|
| + quota_message_filter_.get())->QueryStorageUsageAndQuota(
|
| + storage_partition,
|
| + static_cast<quota::StorageType>(type),
|
| + QuotaDispatcher::CreateWebStorageQuotaCallbacksWrapper(callbacks));
|
| }
|
|
|
| } // namespace content
|
|
|