1
Fork 0

Fix sync_once_cell_does_not_leak_partially_constructed_boxes

Spinning multiple threads in this test causes a deadlock in
SGX where thread scheduling is not preemptive.
This commit is contained in:
Mohsen Zohrevandi 2020-07-21 11:08:37 -07:00
parent 8ad7bc3f42
commit 141adeb493

View file

@ -827,6 +827,8 @@ mod tests {
tx.send(msg).unwrap();
break;
}
#[cfg(target_env = "sgx")]
crate::thread::yield_now();
}
});
}