Skip to content

Commit

Permalink
Check ptr
Browse files Browse the repository at this point in the history
  • Loading branch information
ypo committed Dec 26, 2023
1 parent 456f35e commit 72e48b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sender/observer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ impl ObserverList {
self.0
.write()
.unwrap()
.retain(|a| a.as_ref() as *const _ != s.as_ref() as *const _)
.retain(|a| !std::ptr::eq(a.as_ref() as *const _, s.as_ref() as *const _))
}

pub fn dispatch(&self, event: &Event, now: std::time::SystemTime) {
Expand Down

0 comments on commit 72e48b5

Please sign in to comment.