diff --git a/glommio/src/executor/stall.rs b/glommio/src/executor/stall.rs index f73f381fa..2eae37c39 100644 --- a/glommio/src/executor/stall.rs +++ b/glommio/src/executor/stall.rs @@ -173,6 +173,7 @@ impl StallDetector { unsafe impl Send for SendWrapper {} let tid = SendWrapper(unsafe { nix::libc::pthread_self() }); std::thread::spawn(enclose::enclose! { (terminated, timer) move || { + let tid = tid; while timer.wait().is_ok() { if terminated.load(Ordering::Relaxed) { return