Skip to content

Commit 4fc38ca

Browse files
committed
Add __errno_location on Redox, DragonFlyBSD, Haiku
1 parent 1375b11 commit 4fc38ca

File tree

4 files changed

+4
-2
lines changed

4 files changed

+4
-2
lines changed

src/unix/bsd/freebsdlike/freebsd/mod.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1132,8 +1132,6 @@ f! {
11321132
}
11331133

11341134
extern {
1135-
pub fn __error() -> *mut ::c_int;
1136-
11371135
pub fn clock_getres(clk_id: ::clockid_t, tp: *mut ::timespec) -> ::c_int;
11381136
pub fn clock_gettime(clk_id: ::clockid_t, tp: *mut ::timespec) -> ::c_int;
11391137
pub fn clock_settime(clk_id: ::clockid_t, tp: *const ::timespec) -> ::c_int;

src/unix/bsd/freebsdlike/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1086,6 +1086,8 @@ f! {
10861086
}
10871087

10881088
extern {
1089+
pub fn __error() -> *mut ::c_int;
1090+
10891091
pub fn sem_destroy(sem: *mut sem_t) -> ::c_int;
10901092
pub fn sem_init(sem: *mut sem_t,
10911093
pshared: ::c_int,

src/unix/haiku/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1267,6 +1267,7 @@ extern {
12671267
pub fn setrlimit(resource: ::c_int, rlim: *const ::rlimit) -> ::c_int;
12681268
pub fn strerror_r(errnum: ::c_int, buf: *mut c_char,
12691269
buflen: ::size_t) -> ::c_int;
1270+
pub fn _errnop() -> *mut libc::c_int;
12701271

12711272
pub fn abs(i: ::c_int) -> ::c_int;
12721273
pub fn atof(s: *const ::c_char) -> ::c_double;

src/unix/redox/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -539,6 +539,7 @@ extern {
539539

540540
pub fn strerror_r(errnum: ::c_int, buf: *mut c_char,
541541
buflen: ::size_t) -> ::c_int;
542+
pub fn __errno_location() -> *mut libc::c_int;
542543

543544
// malloc.h
544545
pub fn memalign(align: ::size_t, size: ::size_t) -> *mut ::c_void;

0 commit comments

Comments
 (0)