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

Unified Diff: remoting/host/daemon_process_win.cc

Issue 2424353002: Use ChannelMojo between the remoting daemon and network processes. (Closed)
Patch Set: Created 4 years, 2 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
Index: remoting/host/daemon_process_win.cc
diff --git a/remoting/host/daemon_process_win.cc b/remoting/host/daemon_process_win.cc
index 17961d5a440bca16364b3657484479843c4e8efc..a53f3828768446ec1615e5a86354e2de61135d31 100644
--- a/remoting/host/daemon_process_win.cc
+++ b/remoting/host/daemon_process_win.cc
@@ -25,6 +25,7 @@
#include "base/win/win_util.h"
#include "ipc/ipc_message.h"
#include "ipc/ipc_message_macros.h"
+#include "mojo/edk/embedder/scoped_ipc_support.h"
#include "remoting/base/auto_thread_task_runner.h"
#include "remoting/base/scoped_sc_handle_win.h"
#include "remoting/host/branding.h"
@@ -105,6 +106,8 @@ class DaemonProcessWin : public DaemonProcess {
bool OpenPairingRegistry();
private:
+ mojo::edk::ScopedIPCSupport ipc_support_;
+
std::unique_ptr<WorkerProcessLauncher> network_launcher_;
// Handle of the network process.
@@ -120,8 +123,10 @@ DaemonProcessWin::DaemonProcessWin(
scoped_refptr<AutoThreadTaskRunner> caller_task_runner,
scoped_refptr<AutoThreadTaskRunner> io_task_runner,
const base::Closure& stopped_callback)
- : DaemonProcess(caller_task_runner, io_task_runner, stopped_callback) {
-}
+ : DaemonProcess(caller_task_runner, io_task_runner, stopped_callback),
+ // Mojo holds onto the task runner forever so ignore it when deciding when
+ // to shut down.
joedow 2016/10/20 17:40:03 I'd move this comment to the declaration of the me
Sam McNally 2016/10/20 22:40:22 Done.
+ ipc_support_(io_task_runner->underlying_task_runner()) {}
DaemonProcessWin::~DaemonProcessWin() {
}

Powered by Google App Engine
This is Rietveld 408576698