Skip to content

Commit de97106

Browse files
committed
Handle the UNPARKING state in try_recv
1 parent b3c2688 commit de97106

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,7 @@ impl<T> Receiver<T> {
418418
EMPTY => Err(TryRecvError::Empty),
419419
DISCONNECTED => Err(TryRecvError::Disconnected),
420420
#[cfg(feature = "async")]
421-
RECEIVING => Err(TryRecvError::Empty),
421+
RECEIVING | UNPARKING => Err(TryRecvError::Empty),
422422
_ => unreachable!(),
423423
}
424424
}

0 commit comments

Comments
 (0)