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

Side by Side Diff: remoting/host/win/wts_session_process_delegate.cc

Issue 11231060: [Chromoting] The desktop process now creates a pre-connected pipe and passes (with some help of the… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 8 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « remoting/host/win/worker_process_launcher_unittest.cc ('k') | remoting/remoting.gyp » ('j') | 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 // This file implements the Windows service controlling Me2Me host processes 5 // This file implements the Windows service controlling Me2Me host processes
6 // running within user sessions. 6 // running within user sessions.
7 7
8 #include "remoting/host/win/wts_session_process_delegate.h" 8 #include "remoting/host/win/wts_session_process_delegate.h"
9 9
10 #include "base/base_switches.h" 10 #include "base/base_switches.h"
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 // copying known switches from the caller's command line. 250 // copying known switches from the caller's command line.
251 command_line.SetProgram(daemon_binary); 251 command_line.SetProgram(daemon_binary);
252 command_line.AppendSwitchPath(kElevateSwitchName, binary_path_); 252 command_line.AppendSwitchPath(kElevateSwitchName, binary_path_);
253 253
254 CHECK(ResetEvent(process_exit_event_)); 254 CHECK(ResetEvent(process_exit_event_));
255 } else { 255 } else {
256 command_line.SetProgram(binary_path_); 256 command_line.SetProgram(binary_path_);
257 } 257 }
258 258
259 // Create the server end of the IPC channel. 259 // Create the server end of the IPC channel.
260 std::string channel_name = GenerateIpcChannelName(this); 260 std::string channel_name = IPC::Channel::GenerateUniqueRandomChannelID();
261 ScopedHandle pipe; 261 ScopedHandle pipe;
262 if (!CreateIpcChannel(channel_name, channel_security_, &pipe)) 262 if (!CreateIpcChannel(channel_name, channel_security_, &pipe))
263 return false; 263 return false;
264 264
265 // Wrap the pipe into an IPC channel. 265 // Wrap the pipe into an IPC channel.
266 scoped_ptr<IPC::ChannelProxy> channel(new IPC::ChannelProxy( 266 scoped_ptr<IPC::ChannelProxy> channel(new IPC::ChannelProxy(
267 IPC::ChannelHandle(pipe), 267 IPC::ChannelHandle(pipe),
268 IPC::Channel::MODE_SERVER, 268 IPC::Channel::MODE_SERVER,
269 delegate, 269 delegate,
270 io_task_runner_)); 270 io_task_runner_));
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
520 bool WtsSessionProcessDelegate::LaunchProcess( 520 bool WtsSessionProcessDelegate::LaunchProcess(
521 IPC::Listener* delegate, 521 IPC::Listener* delegate,
522 base::win::ScopedHandle* process_exit_event_out) { 522 base::win::ScopedHandle* process_exit_event_out) {
523 if (!core_) 523 if (!core_)
524 return false; 524 return false;
525 525
526 return core_->LaunchProcess(delegate, process_exit_event_out); 526 return core_->LaunchProcess(delegate, process_exit_event_out);
527 } 527 }
528 528
529 } // namespace remoting 529 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/win/worker_process_launcher_unittest.cc ('k') | remoting/remoting.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698