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

Side by Side Diff: chrome/browser/printing/printing_message_filter.cc

Issue 292443004: Remove IPC_BEGIN_MESSAGE_MAP_EX macro since r270839 made all bad IPCs kill their child processes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: 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 #include "chrome/browser/printing/printing_message_filter.h" 5 #include "chrome/browser/printing/printing_message_filter.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 *thread = BrowserThread::FILE; 108 *thread = BrowserThread::FILE;
109 } 109 }
110 #elif defined(OS_ANDROID) 110 #elif defined(OS_ANDROID)
111 if (message.type() == PrintHostMsg_AllocateTempFileForPrinting::ID || 111 if (message.type() == PrintHostMsg_AllocateTempFileForPrinting::ID ||
112 message.type() == PrintHostMsg_TempFileForPrintingWritten::ID) { 112 message.type() == PrintHostMsg_TempFileForPrintingWritten::ID) {
113 *thread = BrowserThread::UI; 113 *thread = BrowserThread::UI;
114 } 114 }
115 #endif 115 #endif
116 } 116 }
117 117
118 bool PrintingMessageFilter::OnMessageReceived(const IPC::Message& message, 118 bool PrintingMessageFilter::OnMessageReceived(const IPC::Message& message) {
119 bool* message_was_ok) {
120 bool handled = true; 119 bool handled = true;
121 IPC_BEGIN_MESSAGE_MAP_EX(PrintingMessageFilter, message, *message_was_ok) 120 IPC_BEGIN_MESSAGE_MAP(PrintingMessageFilter, message)
122 #if defined(OS_WIN) 121 #if defined(OS_WIN)
123 IPC_MESSAGE_HANDLER(PrintHostMsg_DuplicateSection, OnDuplicateSection) 122 IPC_MESSAGE_HANDLER(PrintHostMsg_DuplicateSection, OnDuplicateSection)
124 #endif 123 #endif
125 #if defined(OS_CHROMEOS) || defined(OS_ANDROID) 124 #if defined(OS_CHROMEOS) || defined(OS_ANDROID)
126 IPC_MESSAGE_HANDLER(PrintHostMsg_AllocateTempFileForPrinting, 125 IPC_MESSAGE_HANDLER(PrintHostMsg_AllocateTempFileForPrinting,
127 OnAllocateTempFileForPrinting) 126 OnAllocateTempFileForPrinting)
128 IPC_MESSAGE_HANDLER(PrintHostMsg_TempFileForPrintingWritten, 127 IPC_MESSAGE_HANDLER(PrintHostMsg_TempFileForPrintingWritten,
129 OnTempFileForPrintingWritten) 128 OnTempFileForPrintingWritten)
130 #endif 129 #endif
131 IPC_MESSAGE_HANDLER(PrintHostMsg_IsPrintingEnabled, OnIsPrintingEnabled) 130 IPC_MESSAGE_HANDLER(PrintHostMsg_IsPrintingEnabled, OnIsPrintingEnabled)
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 469
471 #if defined(ENABLE_FULL_PRINTING) 470 #if defined(ENABLE_FULL_PRINTING)
472 void PrintingMessageFilter::OnCheckForCancel(int32 preview_ui_id, 471 void PrintingMessageFilter::OnCheckForCancel(int32 preview_ui_id,
473 int preview_request_id, 472 int preview_request_id,
474 bool* cancel) { 473 bool* cancel) {
475 PrintPreviewUI::GetCurrentPrintPreviewStatus(preview_ui_id, 474 PrintPreviewUI::GetCurrentPrintPreviewStatus(preview_ui_id,
476 preview_request_id, 475 preview_request_id,
477 cancel); 476 cancel);
478 } 477 }
479 #endif 478 #endif
OLDNEW
« no previous file with comments | « chrome/browser/printing/printing_message_filter.h ('k') | chrome/browser/renderer_host/chrome_render_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698