We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent acddc55 commit 3462175Copy full SHA for 3462175
library/std/src/sync/condvar/tests.rs
@@ -170,14 +170,14 @@ fn wait_timeout_wake() {
170
let t = thread::spawn(move || {
171
let _g = m2.lock().unwrap();
172
thread::sleep(Duration::from_millis(1));
173
- notified_copy.store(true, Ordering::SeqCst);
+ notified_copy.store(true, Ordering::Relaxed);
174
c2.notify_one();
175
});
176
let (g, timeout_res) = c.wait_timeout(g, Duration::from_millis(u64::MAX)).unwrap();
177
assert!(!timeout_res.timed_out());
178
// spurious wakeups mean this isn't necessarily true
179
// so execute test again, if not notified
180
- if !notified.load(Ordering::SeqCst) {
+ if !notified.load(Ordering::Relaxed) {
181
t.join().unwrap();
182
continue;
183
}
0 commit comments