| OLD | NEW |
| 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 "remoting/host/daemon_process.h" | 5 #include "remoting/host/daemon_process.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 base::win::RegKey pairing_registry_unprivileged_key_; | 121 base::win::RegKey pairing_registry_unprivileged_key_; |
| 122 | 122 |
| 123 DISALLOW_COPY_AND_ASSIGN(DaemonProcessWin); | 123 DISALLOW_COPY_AND_ASSIGN(DaemonProcessWin); |
| 124 }; | 124 }; |
| 125 | 125 |
| 126 DaemonProcessWin::DaemonProcessWin( | 126 DaemonProcessWin::DaemonProcessWin( |
| 127 scoped_refptr<AutoThreadTaskRunner> caller_task_runner, | 127 scoped_refptr<AutoThreadTaskRunner> caller_task_runner, |
| 128 scoped_refptr<AutoThreadTaskRunner> io_task_runner, | 128 scoped_refptr<AutoThreadTaskRunner> io_task_runner, |
| 129 const base::Closure& stopped_callback) | 129 const base::Closure& stopped_callback) |
| 130 : DaemonProcess(caller_task_runner, io_task_runner, stopped_callback), | 130 : DaemonProcess(caller_task_runner, io_task_runner, stopped_callback), |
| 131 ipc_support_(io_task_runner->task_runner()) {} | 131 ipc_support_(io_task_runner->task_runner(), |
| 132 mojo::edk::ScopedIPCSupport::ShutdownPolicy::FAST) {} |
| 132 | 133 |
| 133 DaemonProcessWin::~DaemonProcessWin() { | 134 DaemonProcessWin::~DaemonProcessWin() { |
| 134 } | 135 } |
| 135 | 136 |
| 136 void DaemonProcessWin::OnChannelConnected(int32_t peer_pid) { | 137 void DaemonProcessWin::OnChannelConnected(int32_t peer_pid) { |
| 137 // Obtain the handle of the network process. | 138 // Obtain the handle of the network process. |
| 138 network_process_.Set(OpenProcess(PROCESS_DUP_HANDLE, false, peer_pid)); | 139 network_process_.Set(OpenProcess(PROCESS_DUP_HANDLE, false, peer_pid)); |
| 139 if (!network_process_.IsValid()) { | 140 if (!network_process_.IsValid()) { |
| 140 CrashNetworkProcess(FROM_HERE); | 141 CrashNetworkProcess(FROM_HERE); |
| 141 return; | 142 return; |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 371 << "\\" << kPairingRegistrySecretsKeyName; | 372 << "\\" << kPairingRegistrySecretsKeyName; |
| 372 return false; | 373 return false; |
| 373 } | 374 } |
| 374 | 375 |
| 375 pairing_registry_privileged_key_.Set(privileged.Take()); | 376 pairing_registry_privileged_key_.Set(privileged.Take()); |
| 376 pairing_registry_unprivileged_key_.Set(unprivileged.Take()); | 377 pairing_registry_unprivileged_key_.Set(unprivileged.Take()); |
| 377 return true; | 378 return true; |
| 378 } | 379 } |
| 379 | 380 |
| 380 } // namespace remoting | 381 } // namespace remoting |
| OLD | NEW |