File tree Expand file tree Collapse file tree 4 files changed +782
-7
lines changed Expand file tree Collapse file tree 4 files changed +782
-7
lines changed Original file line number Diff line number Diff line change @@ -280,6 +280,8 @@ pub const FLUSHO: ::tcflag_t = 0x00800000;
280
280
pub const PENDIN : :: tcflag_t = 0x20000000 ;
281
281
pub const NOFLSH : :: tcflag_t = 0x80000000 ;
282
282
283
+ pub const WNOHANG : :: c_int = 1 ;
284
+
283
285
f ! {
284
286
pub fn FD_CLR ( fd: :: c_int, set: * mut fd_set) -> ( ) {
285
287
let fd = fd as usize ;
@@ -324,6 +326,12 @@ extern {
324
326
pub fn kqueue ( ) -> :: c_int ;
325
327
pub fn unmount ( target : * const :: c_char , arg : :: c_int ) -> :: c_int ;
326
328
pub fn syscall ( num : :: c_int , ...) -> :: c_int ;
329
+ #[ cfg_attr( target_os = "netbsd" , link_name = "__getpwuid_r50" ) ]
330
+ pub fn getpwuid_r ( uid : :: uid_t ,
331
+ pwd : * mut passwd ,
332
+ buf : * mut :: c_char ,
333
+ buflen : :: size_t ,
334
+ result : * mut * mut passwd ) -> :: c_int ;
327
335
}
328
336
329
337
cfg_if ! {
Original file line number Diff line number Diff line change 99
99
}
100
100
}
101
101
102
- pub const WNOHANG : :: c_int = 1 ;
103
102
pub const SIG_DFL : sighandler_t = 0 as sighandler_t ;
104
103
pub const SIG_IGN : sighandler_t = 1 as sighandler_t ;
105
104
pub const SIG_ERR : sighandler_t = !0 as sighandler_t ;
@@ -621,12 +620,6 @@ extern {
621
620
addrlen : * mut socklen_t ) -> :: ssize_t ;
622
621
pub fn mkfifo ( path : * const c_char , mode : mode_t ) -> :: c_int ;
623
622
624
- #[ cfg_attr( target_os = "netbsd" , link_name = "__getpwuid_r50" ) ]
625
- pub fn getpwuid_r ( uid : :: uid_t ,
626
- pwd : * mut passwd ,
627
- buf : * mut :: c_char ,
628
- buflen : :: size_t ,
629
- result : * mut * mut passwd ) -> :: c_int ;
630
623
#[ cfg_attr( target_os = "netbsd" , link_name = "__sigemptyset14" ) ]
631
624
pub fn sigemptyset ( set : * mut sigset_t ) -> :: c_int ;
632
625
#[ cfg_attr( target_os = "netbsd" , link_name = "__sigaddset14" ) ]
@@ -697,6 +690,9 @@ cfg_if! {
697
690
target_os = "bitrig" ) ) ] {
698
691
mod bsd;
699
692
pub use self :: bsd:: * ;
693
+ } else if #[ cfg( target_os = "sunos" ) ] {
694
+ mod sunos;
695
+ pub use self :: sunos:: * ;
700
696
} else {
701
697
// ...
702
698
}
Original file line number Diff line number Diff line change @@ -523,6 +523,8 @@ pub const CLONE_DETACHED: ::c_int = 0x400000;
523
523
pub const CLONE_UNTRACED : :: c_int = 0x800000 ;
524
524
pub const CLONE_CHILD_SETTID : :: c_int = 0x01000000 ;
525
525
526
+ pub const WNOHANG : :: c_int = 1 ;
527
+
526
528
f ! {
527
529
pub fn FD_CLR ( fd: :: c_int, set: * mut fd_set) -> ( ) {
528
530
let fd = fd as usize ;
@@ -564,6 +566,11 @@ f! {
564
566
}
565
567
566
568
extern {
569
+ pub fn getpwuid_r ( uid : :: uid_t ,
570
+ pwd : * mut passwd ,
571
+ buf : * mut :: c_char ,
572
+ buflen : :: size_t ,
573
+ result : * mut * mut passwd ) -> :: c_int ;
567
574
pub fn fdatasync ( fd : :: c_int ) -> :: c_int ;
568
575
pub fn mincore ( addr : * mut :: c_void , len : :: size_t ,
569
576
vec : * mut :: c_uchar ) -> :: c_int ;
You can’t perform that action at this time.
0 commit comments