Index: chrome/browser/tab_contents/render_view_context_menu.cc |
diff --git a/chrome/browser/tab_contents/render_view_context_menu.cc b/chrome/browser/tab_contents/render_view_context_menu.cc |
index 1cff6df1aeec448330f4d791cb3e9a28d9f456ef..d464b68d97bea624ca442aed4f0642ab9a124769 100644 |
--- a/chrome/browser/tab_contents/render_view_context_menu.cc |
+++ b/chrome/browser/tab_contents/render_view_context_menu.cc |
@@ -1349,12 +1349,13 @@ void RenderViewContextMenu::ExecuteCommand(int id, int event_flags) { |
const GURL& referrer = |
params_.frame_url.is_empty() ? params_.page_url : params_.frame_url; |
const GURL& url = params_.link_url; |
- content::DownloadSaveInfo save_info; |
- save_info.prompt_for_save_location = true; |
+ scoped_ptr<content::DownloadSaveInfo> save_info( |
+ new content::DownloadSaveInfo()); |
+ save_info->prompt_for_save_location = true; |
DownloadManager* dlm = BrowserContext::GetDownloadManager(profile_); |
scoped_ptr<DownloadUrlParameters> dl_params( |
DownloadUrlParameters::FromWebContents( |
- source_web_contents_, url, save_info)); |
+ source_web_contents_, url, save_info.Pass())); |
dl_params->set_referrer( |
content::Referrer(referrer, params_.referrer_policy)); |
dl_params->set_referrer_encoding(params_.frame_charset); |
@@ -1369,8 +1370,9 @@ void RenderViewContextMenu::ExecuteCommand(int id, int event_flags) { |
const GURL& referrer = |
params_.frame_url.is_empty() ? params_.page_url : params_.frame_url; |
const GURL& url = params_.src_url; |
- content::DownloadSaveInfo save_info; |
- save_info.prompt_for_save_location = true; |
+ scoped_ptr<content::DownloadSaveInfo> save_info( |
+ new content::DownloadSaveInfo()); |
+ save_info->prompt_for_save_location = true; |
int64 post_id = -1; |
if (url == source_web_contents_->GetURL()) { |
const NavigationEntry* entry = |
@@ -1381,7 +1383,7 @@ void RenderViewContextMenu::ExecuteCommand(int id, int event_flags) { |
DownloadManager* dlm = BrowserContext::GetDownloadManager(profile_); |
scoped_ptr<DownloadUrlParameters> dl_params( |
DownloadUrlParameters::FromWebContents( |
- source_web_contents_, url, save_info)); |
+ source_web_contents_, url, save_info.Pass())); |
dl_params->set_referrer( |
content::Referrer(referrer, params_.referrer_policy)); |
dl_params->set_post_id(post_id); |