| Index: content/browser/loader/resource_message_filter.cc
|
| diff --git a/content/browser/loader/resource_message_filter.cc b/content/browser/loader/resource_message_filter.cc
|
| index 3d62f2b362a520fdea2af44a1c4b14c0b9fd12d1..d69c9ceae4d46a91e4e3e25020c932ef80b6b5b0 100644
|
| --- a/content/browser/loader/resource_message_filter.cc
|
| +++ b/content/browser/loader/resource_message_filter.cc
|
| @@ -49,6 +49,12 @@ bool ResourceMessageFilter::OnMessageReceived(const IPC::Message& message) {
|
| return ResourceDispatcherHostImpl::Get()->OnMessageReceived(message, this);
|
| }
|
|
|
| +void ResourceMessageFilter::OnDestruct() const {
|
| + // Destroy the filter on the IO thread since that's where its weak pointers
|
| + // are being used.
|
| + BrowserThread::DeleteOnIOThread::Destruct(this);
|
| +}
|
| +
|
| void ResourceMessageFilter::GetContexts(
|
| ResourceType resource_type,
|
| int origin_pid,
|
| @@ -65,6 +71,7 @@ const HostZoomMap* ResourceMessageFilter::GetHostZoomMap() const {
|
| }
|
|
|
| base::WeakPtr<ResourceMessageFilter> ResourceMessageFilter::GetWeakPtr() {
|
| + DCHECK_CURRENTLY_ON(BrowserThread::IO);
|
| return weak_ptr_factory_.GetWeakPtr();
|
| }
|
|
|
|
|