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

Unified Diff: device/serial/data_sender.cc

Issue 2352853002: Disallow redundant Bind calls. (Closed)
Patch Set: use std::move Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: device/serial/data_sender.cc
diff --git a/device/serial/data_sender.cc b/device/serial/data_sender.cc
index 6f12750cbc9d79fbd36b0f59a46bdfdc0b4a0671..b83ddb647c90d690cd96c31998b478686bc52cb3 100644
--- a/device/serial/data_sender.cc
+++ b/device/serial/data_sender.cc
@@ -123,8 +123,7 @@ void DataSender::RunCancelCallback() {
return;
base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE,
- base::Bind(pending_cancel_));
- pending_cancel_.Reset();
danakj 2016/09/24 01:20:01 can you still reset after in case code checks if i
dcheng 2016/09/24 01:29:56 I'm going to add a unit test for this... but this
+ std::move(pending_cancel_));
}
void DataSender::ShutDown() {
« no previous file with comments | « content/browser/tracing/background_tracing_manager_browsertest.cc ('k') | media/audio/android/audio_manager_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698