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

Unified Diff: content/browser/renderer_host/resource_dispatcher_host_impl.cc

Issue 11028131: Shift passage of FileStream in downloads system to be by scoped_ptr<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Incorporated Al's comments. Created 8 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/resource_dispatcher_host_impl.cc
diff --git a/content/browser/renderer_host/resource_dispatcher_host_impl.cc b/content/browser/renderer_host/resource_dispatcher_host_impl.cc
index 607163d0f40730018a8a33f3abeefe14c1f779bd..5b1121599dd3f982cf24e54d89ce51386a0ff884 100644
--- a/content/browser/renderer_host/resource_dispatcher_host_impl.cc
+++ b/content/browser/renderer_host/resource_dispatcher_host_impl.cc
@@ -499,7 +499,7 @@ net::Error ResourceDispatcherHostImpl::BeginDownload(
int child_id,
int route_id,
bool prefer_cache,
- const DownloadSaveInfo& save_info,
+ scoped_ptr<DownloadSaveInfo> save_info,
const DownloadStartedCallback& started_callback) {
if (is_shutdown_)
return CallbackAndReturn(started_callback, net::ERR_INSUFFICIENT_RESOURCES);
@@ -552,7 +552,7 @@ net::Error ResourceDispatcherHostImpl::BeginDownload(
// |started_callback|.
scoped_ptr<ResourceHandler> handler(
CreateResourceHandlerForDownload(request.get(), is_content_initiated,
- save_info, started_callback));
+ save_info.Pass(), started_callback));
BeginRequestInternal(request.Pass(), handler.Pass());
@@ -581,10 +581,10 @@ scoped_ptr<ResourceHandler>
ResourceDispatcherHostImpl::CreateResourceHandlerForDownload(
net::URLRequest* request,
bool is_content_initiated,
- const DownloadSaveInfo& save_info,
+ scoped_ptr<DownloadSaveInfo> save_info,
const DownloadResourceHandler::OnStartedCallback& started_cb) {
scoped_ptr<ResourceHandler> handler(
- new DownloadResourceHandler(request, started_cb, save_info));
+ new DownloadResourceHandler(request, started_cb, save_info.Pass()));
if (delegate_) {
const ResourceRequestInfo* request_info(
ResourceRequestInfo::ForRequest(request));
« no previous file with comments | « content/browser/renderer_host/resource_dispatcher_host_impl.h ('k') | content/browser/web_contents/web_contents_drag_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698