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

Unified Diff: remoting/host/remoting_me2me_host.cc

Issue 12545006: The worker process launcher can now ask the worker to crash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/host/desktop_session_win.cc ('k') | remoting/host/win/unprivileged_process_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/remoting_me2me_host.cc
diff --git a/remoting/host/remoting_me2me_host.cc b/remoting/host/remoting_me2me_host.cc
index 35289fabaf3d679cbf40f875699ac7b70161e227..d243839c1dd5eb1b71b5134bcd42553b8759c6b4 100644
--- a/remoting/host/remoting_me2me_host.cc
+++ b/remoting/host/remoting_me2me_host.cc
@@ -10,6 +10,7 @@
#include "base/bind.h"
#include "base/callback.h"
#include "base/command_line.h"
+#include "base/debug/alias.h"
#include "base/file_util.h"
#include "base/files/file_path.h"
#include "base/logging.h"
@@ -18,6 +19,7 @@
#include "base/single_thread_task_runner.h"
#include "base/string_number_conversions.h"
#include "base/string_util.h"
+#include "base/string_util.h"
#include "base/synchronization/waitable_event.h"
#include "base/threading/thread.h"
#include "base/utf_string_conversions.h"
@@ -535,8 +537,7 @@ bool HostProcess::OnMessageReceived(const IPC::Message& message) {
#if defined(REMOTING_MULTI_PROCESS)
bool handled = true;
IPC_BEGIN_MESSAGE_MAP(HostProcess, message)
- IPC_MESSAGE_HANDLER(ChromotingDaemonNetworkMsg_Crash,
- OnCrash)
+ IPC_MESSAGE_HANDLER(ChromotingDaemonMsg_Crash, OnCrash)
IPC_MESSAGE_HANDLER(ChromotingDaemonNetworkMsg_Configuration,
OnConfigUpdated)
IPC_MESSAGE_FORWARD(
@@ -1102,7 +1103,14 @@ void HostProcess::ShutdownOnNetworkThread() {
void HostProcess::OnCrash(const std::string& function_name,
const std::string& file_name,
const int& line_number) {
- CHECK(false);
+ char message[1024];
+ base::snprintf(message, sizeof(message),
+ "Requested by %s at %s, line %d.",
+ function_name.c_str(), file_name.c_str(), line_number);
+ base::debug::Alias(message);
+
+ // The daemon requested us to crash the process.
+ CHECK(false) << message;
}
int HostProcessMain() {
« no previous file with comments | « remoting/host/desktop_session_win.cc ('k') | remoting/host/win/unprivileged_process_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698