Skip to content

Commit

Permalink
common/cmdparse,msg/async: remove unnecessary std::move()
Browse files Browse the repository at this point in the history
Signed-off-by: Kefu Chai <[email protected]>
  • Loading branch information
tchaikov committed Oct 26, 2016
1 parent 71b1f75 commit 6c4af3c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/common/cmdparse.cc
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ cmdmap_from_json(vector<string> cmd, map<string, cmd_vartype> *mapp, stringstrea
// if an empty array is acceptable, the caller should always check for
// vector<string> if the expected value of "vector<int64_t>" in the
// cmdmap is missing.
(*mapp)[it->first] = std::move(vector<string>());
(*mapp)[it->first] = vector<string>();
} else if (spvals.front().type() == json_spirit::str_type) {
vector<string> outv;
for (const auto& sv : spvals) {
Expand Down
2 changes: 1 addition & 1 deletion src/msg/async/PosixStack.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class PosixNetworkStack : public NetworkStack {
}
virtual void spawn_worker(unsigned i, std::function<void ()> &&func) override {
threads.resize(i+1);
threads[i] = std::move(std::thread(func));
threads[i] = std::thread(func);
}
virtual void join_worker(unsigned i) override {
assert(threads.size() > i && threads[i].joinable());
Expand Down

0 comments on commit 6c4af3c

Please sign in to comment.