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

Unified Diff: remoting/base/stoppable.cc

Issue 10828181: [Chromoting] Moving common logic responsible for launching child processes to WorkerProcessLauncher… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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: remoting/base/stoppable.cc
diff --git a/remoting/base/stoppable.cc b/remoting/base/stoppable.cc
index 88b3c95ef953cdf9fbe840ab4db168954d745a40..db667dc3dc8c99addc2c51d81f0ae4cf6074ece3 100644
--- a/remoting/base/stoppable.cc
+++ b/remoting/base/stoppable.cc
@@ -24,9 +24,12 @@ Stoppable::~Stoppable() {
void Stoppable::Stop() {
DCHECK(task_runner_->BelongsToCurrentThread());
+ // DoStop() can be called multiple times. stoppable_state() can be queried
+ // to tell the first call from the follow up calls.
+ DoStop();
Wez 2012/08/08 20:13:41 Isn't there a risk that something in DoStop() trig
alexeypa (please no reviews) 2012/08/08 21:49:58 This is the intended behavior. :-)
alexeypa (please no reviews) 2012/08/10 16:18:44 It turned out that this breaks stoppable state val
+
if (state_ == kRunning) {
state_ = kStopping;
- DoStop();
}
}
« no previous file with comments | « no previous file | remoting/host/win/launch_process_with_token.h » ('j') | remoting/host/win/launch_process_with_token.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698