mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-09-08 00:00:13 +02:00
@@ -330,8 +330,9 @@ mod dropbox {
|
|||||||
// Try our safe accessor first, and if it works then we know that
|
// Try our safe accessor first, and if it works then we know that
|
||||||
// we're on the right thread. In that case we can simply drop as
|
// we're on the right thread. In that case we can simply drop as
|
||||||
// usual.
|
// usual.
|
||||||
if let Some(a) = self.get_mut().take() {
|
if self.get().is_some() {
|
||||||
return drop(a)
|
drop(self.inner.take().unwrap());
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// If we're on the wrong thread but we actually have some data, then
|
// If we're on the wrong thread but we actually have some data, then
|
||||||
@@ -345,4 +346,3 @@ mod dropbox {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user