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

Unified Diff: webrtc/rtc_base/messagequeue.h

Issue 2968753002: Support re-entrant calls to MessageQueueManager::Clear. (Closed)
Patch Set: Also Post inner handler to verify re-entrant clearing in the message queue works. Created 3 years, 5 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 | webrtc/rtc_base/messagequeue.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/rtc_base/messagequeue.h
diff --git a/webrtc/rtc_base/messagequeue.h b/webrtc/rtc_base/messagequeue.h
index d4057cd2df791dd6c8180aeb2f9788432aad06dd..0d0654e2ecaa8bc5ba8c5b00aab72390da1ed469 100644
--- a/webrtc/rtc_base/messagequeue.h
+++ b/webrtc/rtc_base/messagequeue.h
@@ -70,9 +70,11 @@ class MessageQueueManager {
// This list contains all live MessageQueues.
std::vector<MessageQueue*> message_queues_ GUARDED_BY(crit_);
- // Acquire this with DebugNonReentrantCritScope.
+ // Methods that don't modify the list of message queues may be called in a
+ // re-entrant fashion. "processing_" keeps track of the depth of re-entrant
+ // calls.
CriticalSection crit_;
- bool locked_ GUARDED_BY(crit_);
+ size_t processing_ GUARDED_BY(crit_);
};
// Derive from this for specialized data
« no previous file with comments | « no previous file | webrtc/rtc_base/messagequeue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698