OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Represents the browser side of the browser <--> renderer communication | 5 // Represents the browser side of the browser <--> renderer communication |
6 // channel. There will be one RenderProcessHost per renderer process. | 6 // channel. There will be one RenderProcessHost per renderer process. |
7 | 7 |
8 #include "content/browser/renderer_host/render_process_host_impl.h" | 8 #include "content/browser/renderer_host/render_process_host_impl.h" |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 1022 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1033 | 1033 |
1034 ResourceMessageFilter::GetContextsCallback get_contexts_callback( | 1034 ResourceMessageFilter::GetContextsCallback get_contexts_callback( |
1035 base::Bind(&GetContexts, browser_context->GetResourceContext(), | 1035 base::Bind(&GetContexts, browser_context->GetResourceContext(), |
1036 request_context, media_request_context)); | 1036 request_context, media_request_context)); |
1037 | 1037 |
1038 // Several filters need the Blob storage context, so fetch it in advance. | 1038 // Several filters need the Blob storage context, so fetch it in advance. |
1039 scoped_refptr<ChromeBlobStorageContext> blob_storage_context = | 1039 scoped_refptr<ChromeBlobStorageContext> blob_storage_context = |
1040 ChromeBlobStorageContext::GetFor(browser_context); | 1040 ChromeBlobStorageContext::GetFor(browser_context); |
1041 | 1041 |
1042 resource_message_filter_ = new ResourceMessageFilter( | 1042 resource_message_filter_ = new ResourceMessageFilter( |
1043 GetID(), PROCESS_TYPE_RENDERER, | 1043 GetID(), storage_partition_impl_->GetAppCacheService(), |
1044 storage_partition_impl_->GetAppCacheService(), blob_storage_context.get(), | 1044 blob_storage_context.get(), |
1045 storage_partition_impl_->GetFileSystemContext(), | 1045 storage_partition_impl_->GetFileSystemContext(), |
1046 storage_partition_impl_->GetServiceWorkerContext(), | 1046 storage_partition_impl_->GetServiceWorkerContext(), |
1047 get_contexts_callback); | 1047 get_contexts_callback); |
1048 | 1048 |
1049 AddFilter(resource_message_filter_.get()); | 1049 AddFilter(resource_message_filter_.get()); |
1050 | 1050 |
1051 media::AudioManager* audio_manager = | 1051 media::AudioManager* audio_manager = |
1052 BrowserMainLoop::GetInstance()->audio_manager(); | 1052 BrowserMainLoop::GetInstance()->audio_manager(); |
1053 MediaStreamManager* media_stream_manager = | 1053 MediaStreamManager* media_stream_manager = |
1054 BrowserMainLoop::GetInstance()->media_stream_manager(); | 1054 BrowserMainLoop::GetInstance()->media_stream_manager(); |
(...skipping 1922 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2977 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; | 2977 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; |
2978 | 2978 |
2979 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias | 2979 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias |
2980 // enough information here so that we can determine what the bad message was. | 2980 // enough information here so that we can determine what the bad message was. |
2981 base::debug::Alias(&error); | 2981 base::debug::Alias(&error); |
2982 bad_message::ReceivedBadMessage(render_process_id, | 2982 bad_message::ReceivedBadMessage(render_process_id, |
2983 bad_message::RPH_MOJO_PROCESS_ERROR); | 2983 bad_message::RPH_MOJO_PROCESS_ERROR); |
2984 } | 2984 } |
2985 | 2985 |
2986 } // namespace content | 2986 } // namespace content |
OLD | NEW |