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

Side by Side Diff: content/ppapi_plugin/broker_process_dispatcher.cc

Issue 2717473003: Remove DumpWithoutCrashing() from broker_process_dispatcher (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "content/ppapi_plugin/broker_process_dispatcher.h" 5 #include "content/ppapi_plugin/broker_process_dispatcher.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <memory> 9 #include <memory>
10 10
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/bind_helpers.h" 12 #include "base/bind_helpers.h"
13 #include "base/debug/dump_without_crashing.h"
14 #include "base/strings/utf_string_conversions.h" 13 #include "base/strings/utf_string_conversions.h"
15 #include "build/build_config.h" 14 #include "build/build_config.h"
16 #include "content/child/child_process.h" 15 #include "content/child/child_process.h"
17 #include "ppapi/c/pp_bool.h" 16 #include "ppapi/c/pp_bool.h"
18 #include "ppapi/c/private/ppp_flash_browser_operations.h" 17 #include "ppapi/c/private/ppp_flash_browser_operations.h"
19 #include "ppapi/proxy/ppapi_messages.h" 18 #include "ppapi/proxy/ppapi_messages.h"
20 19
21 namespace content { 20 namespace content {
22 namespace { 21 namespace {
23 22
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 base::TimeDelta::FromSeconds(kBrokerReleaseTimeSeconds)); 111 base::TimeDelta::FromSeconds(kBrokerReleaseTimeSeconds));
113 } 112 }
114 113
115 bool BrokerProcessDispatcher::OnMessageReceived(const IPC::Message& msg) { 114 bool BrokerProcessDispatcher::OnMessageReceived(const IPC::Message& msg) {
116 if (BrokerSideDispatcher::OnMessageReceived(msg)) 115 if (BrokerSideDispatcher::OnMessageReceived(msg))
117 return true; 116 return true;
118 117
119 if (!peer_is_browser_) { 118 if (!peer_is_browser_) {
120 // We might want to consider killing the peer instead is we see problems in 119 // We might want to consider killing the peer instead is we see problems in
121 // the future. 120 // the future.
122 if (msg.type() == PpapiMsg_GetSitesWithData::ID ||
123 msg.type() == PpapiMsg_ClearSiteData::ID ||
124 msg.type() == PpapiMsg_DeauthorizeContentLicenses::ID ||
125 msg.type() == PpapiMsg_GetPermissionSettings::ID ||
126 msg.type() == PpapiMsg_SetDefaultPermission::ID ||
127 msg.type() == PpapiMsg_SetSitePermission::ID) {
128 base::debug::DumpWithoutCrashing();
129 }
130 return false; 121 return false;
131 } 122 }
132 123
133 bool handled = true; 124 bool handled = true;
134 IPC_BEGIN_MESSAGE_MAP(BrokerProcessDispatcher, msg) 125 IPC_BEGIN_MESSAGE_MAP(BrokerProcessDispatcher, msg)
135 IPC_MESSAGE_HANDLER(PpapiMsg_GetSitesWithData, OnGetSitesWithData) 126 IPC_MESSAGE_HANDLER(PpapiMsg_GetSitesWithData, OnGetSitesWithData)
136 IPC_MESSAGE_HANDLER(PpapiMsg_ClearSiteData, OnClearSiteData) 127 IPC_MESSAGE_HANDLER(PpapiMsg_ClearSiteData, OnClearSiteData)
137 IPC_MESSAGE_HANDLER(PpapiMsg_DeauthorizeContentLicenses, 128 IPC_MESSAGE_HANDLER(PpapiMsg_DeauthorizeContentLicenses,
138 OnDeauthorizeContentLicenses) 129 OnDeauthorizeContentLicenses)
139 IPC_MESSAGE_HANDLER(PpapiMsg_GetPermissionSettings, 130 IPC_MESSAGE_HANDLER(PpapiMsg_GetPermissionSettings,
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
344 data_str.c_str(), setting_type, 335 data_str.c_str(), setting_type,
345 static_cast<uint32_t>(sites.size()), site_array.get()); 336 static_cast<uint32_t>(sites.size()), site_array.get());
346 337
347 return PP_ToBool(result); 338 return PP_ToBool(result);
348 } 339 }
349 340
350 return false; 341 return false;
351 } 342 }
352 343
353 } // namespace content 344 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698