Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(688)

Side by Side Diff: content/browser/loader/resource_dispatcher_host_impl.cc

Issue 283623002: Add support for passing an arbitrary parameter to an IPC message handler. The motivation is for Web… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: sync Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
6 6
7 #include "content/browser/loader/resource_dispatcher_host_impl.h" 7 #include "content/browser/loader/resource_dispatcher_host_impl.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <set> 10 #include <set>
(...skipping 841 matching lines...) Expand 10 before | Expand all | Expand 10 after
852 // As the unhandled resource message effectively has no consumer, mark it as 852 // As the unhandled resource message effectively has no consumer, mark it as
853 // handled to prevent needless propagation through the filter pipeline. 853 // handled to prevent needless propagation through the filter pipeline.
854 handled = true; 854 handled = true;
855 } 855 }
856 856
857 filter_ = NULL; 857 filter_ = NULL;
858 return handled; 858 return handled;
859 } 859 }
860 860
861 void ResourceDispatcherHostImpl::OnRequestResource( 861 void ResourceDispatcherHostImpl::OnRequestResource(
862 const IPC::Message& message, 862 int routing_id,
863 int request_id, 863 int request_id,
864 const ResourceHostMsg_Request& request_data) { 864 const ResourceHostMsg_Request& request_data) {
865 BeginRequest(request_id, request_data, NULL, message.routing_id()); 865 BeginRequest(request_id, request_data, NULL, routing_id);
866 } 866 }
867 867
868 // Begins a resource request with the given params on behalf of the specified 868 // Begins a resource request with the given params on behalf of the specified
869 // child process. Responses will be dispatched through the given receiver. The 869 // child process. Responses will be dispatched through the given receiver. The
870 // process ID is used to lookup WebContentsImpl from routing_id's in the case of 870 // process ID is used to lookup WebContentsImpl from routing_id's in the case of
871 // a request from a renderer. request_context is the cookie/cache context to be 871 // a request from a renderer. request_context is the cookie/cache context to be
872 // used for this request. 872 // used for this request.
873 // 873 //
874 // If sync_result is non-null, then a SyncLoad reply will be generated, else 874 // If sync_result is non-null, then a SyncLoad reply will be generated, else
875 // a normal asynchronous set of response messages will be generated. 875 // a normal asynchronous set of response messages will be generated.
(...skipping 1097 matching lines...) Expand 10 before | Expand all | Expand 10 after
1973 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS) 1973 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS)
1974 && !policy->CanReadRawCookies(child_id)) { 1974 && !policy->CanReadRawCookies(child_id)) {
1975 VLOG(1) << "Denied unauthorized request for raw headers"; 1975 VLOG(1) << "Denied unauthorized request for raw headers";
1976 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS; 1976 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS;
1977 } 1977 }
1978 1978
1979 return load_flags; 1979 return load_flags;
1980 } 1980 }
1981 1981
1982 } // namespace content 1982 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/loader/resource_dispatcher_host_impl.h ('k') | content/browser/renderer_host/input/touch_input_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698