Skip to content

Commit acc706d

Browse files
committed
Rollup merge of #23483 - semarie:openbsd-threads, r=alexcrichton
unbreak openbsd/bitrig build - remove `pub` from `struct` (error: visibility has no effect inside functions) - move `pthread_main_np` into function r? @alexcrichton
2 parents b06c9a0 + 95a1e98 commit acc706d

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/libstd/sys/unix/thread.rs

+2-4
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,13 @@ pub mod guard {
130130
#[cfg(any(target_os = "openbsd", target_os = "bitrig"))]
131131
pub unsafe fn current() -> usize {
132132
#[repr(C)]
133-
pub struct stack_t {
133+
struct stack_t {
134134
ss_sp: *mut libc::c_void,
135135
ss_size: libc::size_t,
136136
ss_flags: libc::c_int,
137137
}
138138
extern {
139+
fn pthread_main_np() -> libc::c_uint;
139140
fn pthread_stackseg_np(thread: pthread_t,
140141
sinfo: *mut stack_t) -> libc::c_uint;
141142
}
@@ -339,9 +340,6 @@ fn min_stack_size(_: *const libc::pthread_attr_t) -> libc::size_t {
339340
}
340341

341342
extern {
342-
#[cfg(any(target_os = "bitrig", target_os = "openbsd"))]
343-
fn pthread_main_np() -> libc::c_uint;
344-
345343
fn pthread_self() -> libc::pthread_t;
346344
fn pthread_create(native: *mut libc::pthread_t,
347345
attr: *const libc::pthread_attr_t,

0 commit comments

Comments
 (0)