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

Unified Diff: remoting/host/gcd_state_updater.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: include <utility> Created 5 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/host/gcd_rest_client_unittest.cc ('k') | remoting/host/gcd_state_updater_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/gcd_state_updater.cc
diff --git a/remoting/host/gcd_state_updater.cc b/remoting/host/gcd_state_updater.cc
index 5b9b5786cacbb9d2c78b637cfd618fc3f695397f..c6cc22a4ed12f4d23c247dd2b338b1257254a7a2 100644
--- a/remoting/host/gcd_state_updater.cc
+++ b/remoting/host/gcd_state_updater.cc
@@ -6,6 +6,8 @@
#include <stdint.h>
+#include <utility>
+
#include "base/callback_helpers.h"
#include "base/strings/stringize_macros.h"
#include "base/time/time.h"
@@ -30,7 +32,7 @@ GcdStateUpdater::GcdStateUpdater(
: on_update_successful_callback_(on_update_successful_callback),
on_unknown_host_id_error_(on_unknown_host_id_error),
signal_strategy_(signal_strategy),
- gcd_rest_client_(gcd_rest_client.Pass()) {
+ gcd_rest_client_(std::move(gcd_rest_client)) {
DCHECK(signal_strategy_);
DCHECK(thread_checker_.CalledOnValidThread());
@@ -116,11 +118,11 @@ void GcdStateUpdater::MaybeSendStateUpdate() {
pending_request_jid_ = signal_strategy_->GetLocalJid();
base_state->SetString("_jabberId", pending_request_jid_);
base_state->SetString("_hostVersion", STRINGIZE(VERSION));
- patch->Set("base", base_state.Pass());
+ patch->Set("base", std::move(base_state));
// Send the update to GCD.
gcd_rest_client_->PatchState(
- patch.Pass(),
+ std::move(patch),
base::Bind(&GcdStateUpdater::OnPatchStateResult, base::Unretained(this)));
}
« no previous file with comments | « remoting/host/gcd_rest_client_unittest.cc ('k') | remoting/host/gcd_state_updater_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698