diff --git a/src/compat.rs b/src/compat.rs index e6ad9cc..c2e8b68 100644 --- a/src/compat.rs +++ b/src/compat.rs @@ -46,7 +46,8 @@ where unsafe { if !self.context.0 { //was called by start_send without context - return Poll::Pending; + debug!("start_send without context"); + return Poll::Pending } assert!(!self.context.1.is_null()); let waker = &mut *(self.context.1 as *mut _); @@ -121,7 +122,10 @@ where pub(crate) fn cvt(r: Result) -> Poll> { match r { Ok(v) => Poll::Ready(Ok(v)), - Err(WsError::Io(ref e)) if e.kind() == std::io::ErrorKind::WouldBlock => Poll::Pending, + Err(WsError::Io(ref e)) if e.kind() == std::io::ErrorKind::WouldBlock => { + trace!("WouldBlock"); + Poll::Pending + }, Err(e) => Poll::Ready(Err(e)), } }