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

Unified Diff: mojo/edk/system/awakable_list.cc

Issue 2085583006: Add more tests for AwakableList (esp. persistent vs one-shot awakables). (Closed) Base URL: https://github.com/domokit/mojo.git@work794_wait_set_4.6
Patch Set: Created 4 years, 6 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 | mojo/edk/system/awakable_list_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/awakable_list.cc
diff --git a/mojo/edk/system/awakable_list.cc b/mojo/edk/system/awakable_list.cc
index 3c3799a0bf4b35b547ba68c713b02b144d5c1cc4..b2dde2db1f7b98ae1b7b4fe90cc7f8598ed97422 100644
--- a/mojo/edk/system/awakable_list.cc
+++ b/mojo/edk/system/awakable_list.cc
@@ -37,7 +37,10 @@ void AwakableList::OnStateChange(const HandleSignalsState& old_state,
new_state);
}
} else {
- // One-shot awakables are only called on "leading edge" changes.
+ // One-shot awakables are only called on "leading edge" changes in overall
+ // satisfied-ness or never-satisfiable-ness. (That is, if a one-shot
+ // awakable was previously satisfied and is still satisfied, but for
+ // different reasons, it will not be called.)
if (new_state.satisfies(it->signals) &&
!old_state.satisfies(it->signals)) {
awoken = true;
« no previous file with comments | « no previous file | mojo/edk/system/awakable_list_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698