Skip to content

Commit 0d1d978

Browse files
committed
Handle stack_t.ss_sp type change for DragonFlyBSD
stack_t.ss_sp is now c_void on DragonFlyBSD, so the specialization is no longer needed. Changed in rust-lang/libc@02922ef.
1 parent d5cd320 commit 0d1d978

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

library/std/src/sys/unix/stack_overflow.rs

-14
Original file line numberDiff line numberDiff line change
@@ -161,24 +161,10 @@ mod imp {
161161
stackp.add(page_size())
162162
}
163163

164-
#[cfg(any(
165-
target_os = "linux",
166-
target_os = "macos",
167-
target_os = "freebsd",
168-
target_os = "netbsd",
169-
target_os = "openbsd",
170-
target_os = "solaris",
171-
target_os = "illumos"
172-
))]
173164
unsafe fn get_stack() -> libc::stack_t {
174165
libc::stack_t { ss_sp: get_stackp(), ss_flags: 0, ss_size: SIGSTKSZ }
175166
}
176167

177-
#[cfg(target_os = "dragonfly")]
178-
unsafe fn get_stack() -> libc::stack_t {
179-
libc::stack_t { ss_sp: get_stackp() as *mut i8, ss_flags: 0, ss_size: SIGSTKSZ }
180-
}
181-
182168
pub unsafe fn make_handler() -> Handler {
183169
if !NEED_ALTSTACK.load(Ordering::Relaxed) {
184170
return Handler::null();

0 commit comments

Comments
 (0)