File tree 11 files changed +16
-1
lines changed
11 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -2659,6 +2659,7 @@ extern {
2659
2659
fd : :: c_int ,
2660
2660
newfd : :: c_int ,
2661
2661
) -> :: c_int ;
2662
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
2662
2663
}
2663
2664
2664
2665
cfg_if ! {
Original file line number Diff line number Diff line change @@ -801,4 +801,5 @@ extern {
801
801
802
802
pub fn statfs ( path : * const :: c_char , buf : * mut statfs ) -> :: c_int ;
803
803
pub fn fstatfs ( fd : :: c_int , buf : * mut statfs ) -> :: c_int ;
804
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
804
805
}
Original file line number Diff line number Diff line change @@ -949,6 +949,12 @@ pub const UF_READONLY: ::c_ulong = 0x00001000;
949
949
pub const UF_HIDDEN : :: c_ulong = 0x00008000 ;
950
950
pub const SF_SNAPSHOT : :: c_ulong = 0x00200000 ;
951
951
952
+ f ! {
953
+ pub fn uname( buf: * mut :: utsname) -> :: c_int {
954
+ __xuname( 256 , buf as * mut :: c_void)
955
+ }
956
+ }
957
+
952
958
extern {
953
959
pub fn __error ( ) -> * mut :: c_int ;
954
960
@@ -1135,6 +1141,7 @@ extern {
1135
1141
pub fn fstatfs ( fd : :: c_int , buf : * mut statfs ) -> :: c_int ;
1136
1142
1137
1143
pub fn dup3 ( src : :: c_int , dst : :: c_int , flags : :: c_int ) -> :: c_int ;
1144
+ pub fn __xuname ( nmln : :: c_int , buf : * mut :: c_void ) -> :: c_int ;
1138
1145
}
1139
1146
1140
1147
#[ link( name = "util" ) ]
Original file line number Diff line number Diff line change @@ -676,6 +676,7 @@ extern {
676
676
-> :: c_int ;
677
677
pub fn getdomainname ( name : * mut :: c_char , len : :: size_t ) -> :: c_int ;
678
678
pub fn setdomainname ( name : * const :: c_char , len : :: size_t ) -> :: c_int ;
679
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
679
680
}
680
681
681
682
cfg_if ! {
Original file line number Diff line number Diff line change @@ -1242,6 +1242,7 @@ extern {
1242
1242
termp : * mut termios ,
1243
1243
winp : * mut :: winsize ) -> :: pid_t ;
1244
1244
pub fn sethostname ( name : * const :: c_char , len : :: size_t ) -> :: c_int ;
1245
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
1245
1246
}
1246
1247
1247
1248
cfg_if ! {
Original file line number Diff line number Diff line change @@ -727,6 +727,7 @@ extern {
727
727
-> :: c_int ;
728
728
729
729
pub fn setgroups ( ngroups : :: c_int , grouplist : * const :: gid_t ) -> :: c_int ;
730
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
730
731
}
731
732
732
733
cfg_if ! {
Original file line number Diff line number Diff line change @@ -972,7 +972,6 @@ extern {
972
972
#[ cfg_attr( target_os = "freebsd" , link_name = "mknod@FBSD_1.0" ) ]
973
973
pub fn mknod ( pathname : * const :: c_char , mode : :: mode_t ,
974
974
dev : :: dev_t ) -> :: c_int ;
975
- pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
976
975
pub fn gethostname ( name : * mut :: c_char , len : :: size_t ) -> :: c_int ;
977
976
pub fn getservbyname ( name : * const :: c_char ,
978
977
proto : * const :: c_char ) -> * mut servent ;
Original file line number Diff line number Diff line change @@ -728,6 +728,7 @@ extern {
728
728
link_name = "popen$UNIX2003" ) ]
729
729
pub fn popen ( command : * const c_char ,
730
730
mode : * const c_char ) -> * mut :: FILE ;
731
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
731
732
}
732
733
733
734
cfg_if ! {
Original file line number Diff line number Diff line change @@ -1242,6 +1242,7 @@ extern {
1242
1242
flags : :: c_int ) -> :: ssize_t ;
1243
1243
pub fn recvmsg ( fd : :: c_int , msg : * mut :: msghdr , flags : :: c_int )
1244
1244
-> :: ssize_t ;
1245
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
1245
1246
}
1246
1247
1247
1248
cfg_if ! {
Original file line number Diff line number Diff line change @@ -1466,4 +1466,5 @@ extern {
1466
1466
mode : * const c_char ) -> * mut :: FILE ;
1467
1467
1468
1468
pub fn dup3 ( src : :: c_int , dst : :: c_int , flags : :: c_int ) -> :: c_int ;
1469
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
1469
1470
}
Original file line number Diff line number Diff line change @@ -1953,6 +1953,7 @@ extern {
1953
1953
link_name = "popen$UNIX2003" ) ]
1954
1954
pub fn popen ( command : * const c_char ,
1955
1955
mode : * const c_char ) -> * mut :: FILE ;
1956
+ pub fn uname ( buf : * mut :: utsname ) -> :: c_int ;
1956
1957
}
1957
1958
1958
1959
cfg_if ! {
You can’t perform that action at this time.
0 commit comments