diff options
author | cimamoglu@chromium.org <cimamoglu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-08-23 12:55:32 +0000 |
---|---|---|
committer | cimamoglu@chromium.org <cimamoglu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-08-23 12:55:32 +0000 |
commit | b9321a7718775af0c67628133405eb5d66c308b5 (patch) | |
tree | a12c69130cf2b007cd20c53026da99575b378464 /chrome/browser/printing | |
parent | 39b2bafb4d240e34cf594bca4348b16e63f2b050 (diff) | |
download | chromium_src-b9321a7718775af0c67628133405eb5d66c308b5.zip chromium_src-b9321a7718775af0c67628133405eb5d66c308b5.tar.gz chromium_src-b9321a7718775af0c67628133405eb5d66c308b5.tar.bz2 |
Two small fixes for Chrome for Android PDF printing.
BUG=147070
Review URL: https://chromiumcodereview.appspot.com/23264039
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@219271 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/printing')
-rw-r--r-- | chrome/browser/printing/printing_message_filter.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/chrome/browser/printing/printing_message_filter.cc b/chrome/browser/printing/printing_message_filter.cc index 2f8eb10..7c66ae8 100644 --- a/chrome/browser/printing/printing_message_filter.cc +++ b/chrome/browser/printing/printing_message_filter.cc @@ -361,6 +361,11 @@ void PrintingMessageFilter::OnScriptedPrintReply( scoped_refptr<printing::PrinterQuery> printer_query, IPC::Message* reply_msg) { PrintMsg_PrintPages_Params params; +#if defined(OS_ANDROID) + // We need to save the routing ID here because Send method below deletes the + // |reply_msg| before we can get the routing ID for the Android code. + int routing_id = reply_msg->routing_id(); +#endif if (printer_query->last_status() != printing::PrintingContext::OK || !printer_query->settings().dpi()) { params.Reset(); @@ -380,7 +385,7 @@ void PrintingMessageFilter::OnScriptedPrintReply( BrowserThread::PostTask( BrowserThread::UI, FROM_HERE, base::Bind(&PrintingMessageFilter::UpdateFileDescriptor, this, - reply_msg->routing_id(), file_descriptor)); + routing_id, file_descriptor)); } #endif print_job_manager_->QueuePrinterQuery(printer_query.get()); |