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

Unified Diff: base/message_loop.cc

Issue 6374010: Add MessageLoop::AssertIdle(). Use in ChromeOS audio threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 11 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 | « base/message_loop.h ('k') | chrome/browser/chromeos/audio_mixer_alsa.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop.cc
diff --git a/base/message_loop.cc b/base/message_loop.cc
index 518a0fd25989864f1dcbe539f10c4f51e5b44384..220d2ea5a770acf7bbd52a6f25036d604a32475c 100644
--- a/base/message_loop.cc
+++ b/base/message_loop.cc
@@ -286,6 +286,11 @@ void MessageLoop::RemoveTaskObserver(TaskObserver* task_observer) {
task_observers_.RemoveObserver(task_observer);
}
+void MessageLoop::AssertIdle() const {
+ base::AutoLock lock(incoming_queue_lock_);
+ DCHECK(incoming_queue_.empty());
darin (slow to review) 2011/01/25 17:07:43 what about the work_queue_?
willchan no longer on Chromium 2011/01/25 17:12:01 See my comment in the .h file: // Asserts that the
+}
+
//------------------------------------------------------------------------------
// Runs the loop in two different SEH modes:
« no previous file with comments | « base/message_loop.h ('k') | chrome/browser/chromeos/audio_mixer_alsa.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698