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

Side by Side Diff: remoting/host/setup/daemon_controller_delegate_linux.cc

Issue 1549493004: Use std::move() instead of .Pass() in remoting/host (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_not_pass
Patch Set: Created 4 years, 12 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/setup/daemon_controller_delegate_linux.h" 5 #include "remoting/host/setup/daemon_controller_delegate_linux.h"
6 6
7 #include <unistd.h> 7 #include <unistd.h>
8 8
9 #include "base/base_paths.h" 9 #include "base/base_paths.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 return nullptr; 133 return nullptr;
134 134
135 scoped_ptr<base::DictionaryValue> result(new base::DictionaryValue()); 135 scoped_ptr<base::DictionaryValue> result(new base::DictionaryValue());
136 std::string value; 136 std::string value;
137 if (config->GetString(kHostIdConfigPath, &value)) { 137 if (config->GetString(kHostIdConfigPath, &value)) {
138 result->SetString(kHostIdConfigPath, value); 138 result->SetString(kHostIdConfigPath, value);
139 } 139 }
140 if (config->GetString(kXmppLoginConfigPath, &value)) { 140 if (config->GetString(kXmppLoginConfigPath, &value)) {
141 result->SetString(kXmppLoginConfigPath, value); 141 result->SetString(kXmppLoginConfigPath, value);
142 } 142 }
143 return result.Pass(); 143 return result;
144 } 144 }
145 145
146 void DaemonControllerDelegateLinux::SetConfigAndStart( 146 void DaemonControllerDelegateLinux::SetConfigAndStart(
147 scoped_ptr<base::DictionaryValue> config, 147 scoped_ptr<base::DictionaryValue> config,
148 bool consent, 148 bool consent,
149 const DaemonController::CompletionCallback& done) { 149 const DaemonController::CompletionCallback& done) {
150 // Add the user to chrome-remote-desktop group first. 150 // Add the user to chrome-remote-desktop group first.
151 std::vector<std::string> args; 151 std::vector<std::string> args;
152 args.push_back("--add-user"); 152 args.push_back("--add-user");
153 if (!RunHostScript(args)) { 153 if (!RunHostScript(args)) {
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 // Crash dump collection is not implemented on Linux yet. 223 // Crash dump collection is not implemented on Linux yet.
224 // http://crbug.com/130678. 224 // http://crbug.com/130678.
225 DaemonController::UsageStatsConsent consent; 225 DaemonController::UsageStatsConsent consent;
226 consent.supported = false; 226 consent.supported = false;
227 consent.allowed = false; 227 consent.allowed = false;
228 consent.set_by_policy = false; 228 consent.set_by_policy = false;
229 return consent; 229 return consent;
230 } 230 }
231 231
232 scoped_refptr<DaemonController> DaemonController::Create() { 232 scoped_refptr<DaemonController> DaemonController::Create() {
233 scoped_ptr<DaemonController::Delegate> delegate( 233 return new DaemonController(
234 new DaemonControllerDelegateLinux()); 234 make_scoped_ptr(new DaemonControllerDelegateLinux()));
235 return new DaemonController(delegate.Pass());
236 } 235 }
237 236
238 } // namespace remoting 237 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698