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

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

Issue 290173011: Cleanup: Use base::CommandLine in remoting/ (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
OLDNEW
1 1
2 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be 3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file. 4 // found in the LICENSE file.
5 // 5 //
6 // This file implements the Windows service controlling Me2Me host processes 6 // This file implements the Windows service controlling Me2Me host processes
7 // running within user sessions. 7 // running within user sessions.
8 8
9 #include "remoting/host/win/unprivileged_process_delegate.h" 9 #include "remoting/host/win/unprivileged_process_delegate.h"
10 10
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 return; 284 return;
285 } 285 }
286 ScopedHandle client(temp_handle); 286 ScopedHandle client(temp_handle);
287 287
288 // Convert the handle value into a decimal integer. Handle values are 32bit 288 // Convert the handle value into a decimal integer. Handle values are 32bit
289 // even on 64bit platforms. 289 // even on 64bit platforms.
290 std::string pipe_handle = base::StringPrintf( 290 std::string pipe_handle = base::StringPrintf(
291 "%d", reinterpret_cast<ULONG_PTR>(client.Get())); 291 "%d", reinterpret_cast<ULONG_PTR>(client.Get()));
292 292
293 // Pass the IPC channel via the command line. 293 // Pass the IPC channel via the command line.
294 CommandLine command_line(target_command_->argv()); 294 base::CommandLine command_line(target_command_->argv());
295 command_line.AppendSwitchASCII(kDaemonPipeSwitchName, pipe_handle); 295 command_line.AppendSwitchASCII(kDaemonPipeSwitchName, pipe_handle);
296 296
297 // Create our own window station and desktop accessible by |logon_sid|. 297 // Create our own window station and desktop accessible by |logon_sid|.
298 WindowStationAndDesktop handles; 298 WindowStationAndDesktop handles;
299 if (!CreateWindowStationAndDesktop(logon_sid.Pass(), &handles)) { 299 if (!CreateWindowStationAndDesktop(logon_sid.Pass(), &handles)) {
300 PLOG(ERROR) << "Failed to create a window station and desktop"; 300 PLOG(ERROR) << "Failed to create a window station and desktop";
301 ReportFatalError(); 301 ReportFatalError();
302 return; 302 return;
303 } 303 }
304 304
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
411 0)) { 411 0)) {
412 PLOG(ERROR) << "Failed to duplicate a handle"; 412 PLOG(ERROR) << "Failed to duplicate a handle";
413 ReportFatalError(); 413 ReportFatalError();
414 return; 414 return;
415 } 415 }
416 ScopedHandle limited_handle(temp_handle); 416 ScopedHandle limited_handle(temp_handle);
417 417
418 event_handler_->OnProcessLaunched(limited_handle.Pass()); 418 event_handler_->OnProcessLaunched(limited_handle.Pass());
419 } 419 }
420 420
421 } // namespace remoting 421 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/win/launch_process_with_token.cc ('k') | remoting/host/win/wts_session_process_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698