fix single_threaded_poll, perform final polls until empty
@@ -141,12 +141,18 @@ mod stress {
}
}
- // One final poll
+ // Finall polls, repeat until readiness-queue empty
+ loop {
+ // Might not read all events from custom-event-queue at once, implementation dependend
poll.poll(&mut events, Some(Duration::from_millis(0))).unwrap();
-
+ if events.is_empty() {
+ // no more events in readiness queue pending
+ break;
+ }
for event in &events {
ready[event.token().0] = event.readiness();
}
+ }
// Everything should be flagged as readable
for ready in ready {
