mirror of
https://github.com/Revertron/Alfis
synced 2024-11-18 21:26:38 +00:00
Hopefully fixed spurious wakeups of 'mio.poll'.
This commit is contained in:
parent
3072fefb38
commit
588ac6ae00
@ -168,6 +168,10 @@ fn handle_connection_event(context: Arc<Mutex<Context>>, peers: &mut Peers, regi
|
||||
if event.is_error() || (event.is_read_closed() && event.is_write_closed()) {
|
||||
return false;
|
||||
}
|
||||
if event.is_readable() && event.is_read_closed() {
|
||||
info!("Spurious wakeup for connection {}, ignoring", event.token().0);
|
||||
return true;
|
||||
}
|
||||
|
||||
if event.is_readable() {
|
||||
let data = {
|
||||
|
Loading…
Reference in New Issue
Block a user