| 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/desktop_session_win.h" | 5 #include "remoting/host/desktop_session_win.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 #include <sddl.h> | 8 #include <sddl.h> |
| 9 | 9 |
| 10 #include "base/base_switches.h" | 10 #include "base/base_switches.h" |
| (...skipping 511 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 522 result = GetInstalledBinaryPath(kHostBinaryName, &desktop_binary); | 522 result = GetInstalledBinaryPath(kHostBinaryName, &desktop_binary); |
| 523 } | 523 } |
| 524 | 524 |
| 525 if (!result) { | 525 if (!result) { |
| 526 TerminateSession(); | 526 TerminateSession(); |
| 527 return; | 527 return; |
| 528 } | 528 } |
| 529 | 529 |
| 530 session_attach_timer_.Stop(); | 530 session_attach_timer_.Stop(); |
| 531 | 531 |
| 532 scoped_ptr<CommandLine> target(new CommandLine(desktop_binary)); | 532 scoped_ptr<base::CommandLine> target(new base::CommandLine(desktop_binary)); |
| 533 target->AppendSwitchASCII(kProcessTypeSwitchName, kProcessTypeDesktop); | 533 target->AppendSwitchASCII(kProcessTypeSwitchName, kProcessTypeDesktop); |
| 534 // Copy the command line switches enabling verbose logging. | 534 // Copy the command line switches enabling verbose logging. |
| 535 target->CopySwitchesFrom(*CommandLine::ForCurrentProcess(), | 535 target->CopySwitchesFrom(*base::CommandLine::ForCurrentProcess(), |
| 536 kCopiedSwitchNames, | 536 kCopiedSwitchNames, arraysize(kCopiedSwitchNames)); |
| 537 arraysize(kCopiedSwitchNames)); | |
| 538 | 537 |
| 539 // Create a delegate capable of launching a process in a different session. | 538 // Create a delegate capable of launching a process in a different session. |
| 540 scoped_ptr<WtsSessionProcessDelegate> delegate( | 539 scoped_ptr<WtsSessionProcessDelegate> delegate( |
| 541 new WtsSessionProcessDelegate(io_task_runner_, | 540 new WtsSessionProcessDelegate(io_task_runner_, |
| 542 target.Pass(), | 541 target.Pass(), |
| 543 launch_elevated, | 542 launch_elevated, |
| 544 base::WideToUTF8( | 543 base::WideToUTF8( |
| 545 kDaemonIpcSecurityDescriptor))); | 544 kDaemonIpcSecurityDescriptor))); |
| 546 if (!delegate->Initialize(session_id)) { | 545 if (!delegate->Initialize(session_id)) { |
| 547 TerminateSession(); | 546 TerminateSession(); |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 599 exploded.hour, | 598 exploded.hour, |
| 600 exploded.minute, | 599 exploded.minute, |
| 601 exploded.second, | 600 exploded.second, |
| 602 exploded.millisecond, | 601 exploded.millisecond, |
| 603 passed.c_str()); | 602 passed.c_str()); |
| 604 | 603 |
| 605 last_timestamp_ = now; | 604 last_timestamp_ = now; |
| 606 } | 605 } |
| 607 | 606 |
| 608 } // namespace remoting | 607 } // namespace remoting |
| OLD | NEW |