diff --git a/src/select.rs b/src/select.rs index 2fdcfef..cec4a96 100644 --- a/src/select.rs +++ b/src/select.rs @@ -282,7 +282,7 @@ impl<'a, T> Selector<'a, T> { let hook: Arc> = hook; wait_lock(&self.receiver.shared.chan) .waiting - .retain(|s| !Arc::ptr_eq(s, &hook)); + .retain(|s| s.signal().as_ptr() != hook.signal().as_ptr()); // If we were woken, but never polled, wake up another if !self.received && hook