summaryrefslogtreecommitdiffstats
path: root/remoting/host/gcd_state_updater.cc
diff options
context:
space:
mode:
authorsergeyu <sergeyu@chromium.org>2015-12-23 11:01:22 -0800
committerCommit bot <commit-bot@chromium.org>2015-12-23 19:02:20 +0000
commit1417e013d741b99685fee8f3d3c166f597655eda (patch)
tree6a2ab7f1547bd187cb4eb8e037f8ed69ca36eed1 /remoting/host/gcd_state_updater.cc
parent090488ff3ff55782b02a1b2965bdbe2acd0b8f53 (diff)
downloadchromium_src-1417e013d741b99685fee8f3d3c166f597655eda.zip
chromium_src-1417e013d741b99685fee8f3d3c166f597655eda.tar.gz
chromium_src-1417e013d741b99685fee8f3d3c166f597655eda.tar.bz2
Use std::move() instead of .Pass() in remoting/host
Now there is a presubmit check that doesn't allow Pass() anymore. See https://www.chromium.org/rvalue-references for information about std::move in chromium. Review URL: https://codereview.chromium.org/1549493004 Cr-Commit-Position: refs/heads/master@{#366759}
Diffstat (limited to 'remoting/host/gcd_state_updater.cc')
-rw-r--r--remoting/host/gcd_state_updater.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/remoting/host/gcd_state_updater.cc b/remoting/host/gcd_state_updater.cc
index 5b9b578..c6cc22a 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)));
}