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

Unified Diff: chrome/browser/renderer_host/render_widget_host.cc

Issue 5978003: Make IPC::Channel::Listener:OnMessageReceived have a return value indicating ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years 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: chrome/browser/renderer_host/render_widget_host.cc
===================================================================
--- chrome/browser/renderer_host/render_widget_host.cc (revision 70108)
+++ chrome/browser/renderer_host/render_widget_host.cc (working copy)
@@ -151,7 +151,8 @@
return false;
}
-void RenderWidgetHost::OnMessageReceived(const IPC::Message &msg) {
+bool RenderWidgetHost::OnMessageReceived(const IPC::Message &msg) {
+ bool handled = true;
bool msg_is_ok = true;
IPC_BEGIN_MESSAGE_MAP_EX(RenderWidgetHost, msg, msg_is_ok)
IPC_MESSAGE_HANDLER(ViewHostMsg_RenderViewReady, OnMsgRenderViewReady)
@@ -192,7 +193,7 @@
IPC_MESSAGE_HANDLER(ViewHostMsg_DestroyPluginContainer,
OnMsgDestroyPluginContainer)
#endif
- IPC_MESSAGE_UNHANDLED_ERROR()
+ IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP_EX()
if (!msg_is_ok) {
@@ -200,6 +201,7 @@
UserMetrics::RecordAction(UserMetricsAction("BadMessageTerminate_RWH"));
process()->ReceivedBadMessage();
}
+ return handled;
}
bool RenderWidgetHost::Send(IPC::Message* msg) {
« no previous file with comments | « chrome/browser/renderer_host/render_widget_host.h ('k') | chrome/browser/renderer_host/test/test_render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698