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

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

Issue 953793003: Ensuring interception of stream get determined by plugin path before checking mime type. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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
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 // This is the browser side of the resource dispatcher, it receives requests 5 // This is the browser side of the resource dispatcher, it receives requests
6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and 6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and
7 // dispatches them to URLRequests. It then forwards the messages from the 7 // dispatches them to URLRequests. It then forwards the messages from the
8 // URLRequests back to the correct process for handling. 8 // URLRequests back to the correct process for handling.
9 // 9 //
10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 uint32 id, 235 uint32 id,
236 scoped_ptr<DownloadSaveInfo> save_info, 236 scoped_ptr<DownloadSaveInfo> save_info,
237 const DownloadUrlParameters::OnStartedCallback& started_cb); 237 const DownloadUrlParameters::OnStartedCallback& started_cb);
238 238
239 // Must be called after the ResourceRequestInfo has been created 239 // Must be called after the ResourceRequestInfo has been created
240 // and associated with the request. If |payload| is set to a non-empty value, 240 // and associated with the request. If |payload| is set to a non-empty value,
241 // the value will be sent to the old resource handler instead of canceling 241 // the value will be sent to the old resource handler instead of canceling
242 // it, except on HTTP errors. This is marked virtual so it can be overriden in 242 // it, except on HTTP errors. This is marked virtual so it can be overriden in
243 // testing. 243 // testing.
244 virtual scoped_ptr<ResourceHandler> MaybeInterceptAsStream( 244 virtual scoped_ptr<ResourceHandler> MaybeInterceptAsStream(
245 const base::FilePath& file_path,
raymes 2015/03/12 05:21:03 plugin_path
Deepak 2015/03/12 12:33:18 Done.
245 net::URLRequest* request, 246 net::URLRequest* request,
246 ResourceResponse* response, 247 ResourceResponse* response,
247 std::string* payload); 248 std::string* payload);
248 249
249 ResourceScheduler* scheduler() { return scheduler_.get(); } 250 ResourceScheduler* scheduler() { return scheduler_.get(); }
250 251
251 // Called by a ResourceHandler when it's ready to start reading data and 252 // Called by a ResourceHandler when it's ready to start reading data and
252 // sending it to the renderer. Returns true if there are enough file 253 // sending it to the renderer. Returns true if there are enough file
253 // descriptors available for the shared memory buffer. If false is returned, 254 // descriptors available for the shared memory buffer. If false is returned,
254 // the request should cancel. 255 // the request should cancel.
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 DelegateMap delegate_map_; 582 DelegateMap delegate_map_;
582 583
583 scoped_ptr<ResourceScheduler> scheduler_; 584 scoped_ptr<ResourceScheduler> scheduler_;
584 585
585 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl); 586 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl);
586 }; 587 };
587 588
588 } // namespace content 589 } // namespace content
589 590
590 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_ 591 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698