diff --git a/ntex-net/src/rt_polling/driver.rs b/ntex-net/src/rt_polling/driver.rs index becc9aeb..b830fcca 100644 --- a/ntex-net/src/rt_polling/driver.rs +++ b/ntex-net/src/rt_polling/driver.rs @@ -156,6 +156,8 @@ impl Handler for StreamOpsHandler { if result.is_pending() { item.flags.insert(Flags::RD); self.inner.api.register(item.fd, id, Interest::Readable); + } else { + item.flags.remove(Flags::RD); } } Change::Writable => { @@ -170,6 +172,8 @@ impl Handler for StreamOpsHandler { if result.is_pending() { item.flags.insert(Flags::WR); self.inner.api.register(item.fd, id, Interest::Writable); + } else { + item.flags.remove(Flags::WR); } } Change::Error(err) => {