mirror of
https://github.com/embassy-rs/embassy.git
synced 2024-11-25 16:23:10 +00:00
Add check for closed connection to read_ready()
This commit is contained in:
parent
bd0243d12f
commit
c3be54f96b
@ -587,7 +587,7 @@ mod embedded_io_impls {
|
||||
|
||||
impl<'d> embedded_io_async::ReadReady for TcpSocket<'d> {
|
||||
fn read_ready(&mut self) -> Result<bool, Self::Error> {
|
||||
Ok(self.io.with(|s, _| s.can_recv()))
|
||||
Ok(self.io.with(|s, _| s.can_recv() || !s.may_recv()))
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user