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

Unified Diff: base/threading/thread.h

Issue 10399097: Base: Don't overwrite the thread id when ThreadMain exits. There's (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 7 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
« no previous file with comments | « no previous file | base/threading/thread.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/threading/thread.h
===================================================================
--- base/threading/thread.h (revision 138018)
+++ base/threading/thread.h (working copy)
@@ -131,8 +131,7 @@
PlatformThreadId thread_id() const { return thread_id_; }
// Returns true if the thread has been started, and not yet stopped.
- // When a thread is running, |thread_id_| is a valid id.
- bool IsRunning() const { return thread_id_ != kInvalidThreadId; }
+ bool IsRunning() const;
protected:
// Called just prior to starting the message loop
@@ -164,6 +163,9 @@
// |message_loop_|. It may non-NULL and invalid.
bool stopping_;
+ // True while inside of Run().
+ bool running_;
+
// Used to pass data to ThreadMain.
struct StartupData;
StartupData* startup_data_;
« no previous file with comments | « no previous file | base/threading/thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698