We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 33a32f2 commit 72c7444Copy full SHA for 72c7444
std/src/sys/pal/unix/stack_overflow.rs
@@ -155,8 +155,13 @@ mod imp {
155
}
156
157
158
+ /// # Safety
159
+ /// Must be called only once
160
+ #[forbid(unsafe_op_in_unsafe_fn)]
161
pub unsafe fn cleanup() {
- drop_handler(MAIN_ALTSTACK.load(Ordering::Relaxed));
162
+ // FIXME: I probably cause more bugs than I'm worth!
163
+ // see https://github.com/rust-lang/rust/issues/111272
164
+ unsafe { drop_handler(MAIN_ALTSTACK.load(Ordering::Relaxed)) };
165
166
167
unsafe fn get_stack() -> libc::stack_t {
0 commit comments