@@ -2877,6 +2877,7 @@ pub struct User {
2877
2877
/// Login class
2878
2878
#[ cfg( not( any( target_os = "android" ,
2879
2879
target_os = "fuchsia" ,
2880
+ target_os = "haiku" ,
2880
2881
target_os = "illumos" ,
2881
2882
target_os = "linux" ,
2882
2883
target_os = "solaris" ) ) ) ]
@@ -2885,6 +2886,7 @@ pub struct User {
2885
2886
/// Last password change
2886
2887
#[ cfg( not( any( target_os = "android" ,
2887
2888
target_os = "fuchsia" ,
2889
+ target_os = "haiku" ,
2888
2890
target_os = "illumos" ,
2889
2891
target_os = "linux" ,
2890
2892
target_os = "solaris" ) ) ) ]
@@ -2893,14 +2895,15 @@ pub struct User {
2893
2895
/// Expiration time of account
2894
2896
#[ cfg( not( any( target_os = "android" ,
2895
2897
target_os = "fuchsia" ,
2898
+ target_os = "haiku" ,
2896
2899
target_os = "illumos" ,
2897
2900
target_os = "linux" ,
2898
2901
target_os = "solaris" ) ) ) ]
2899
2902
#[ cfg_attr( docsrs, doc( cfg( all( ) ) ) ) ]
2900
2903
pub expire: libc:: time_t
2901
2904
}
2902
2905
2903
- #[ cfg( not( any ( target_os = "redox" , target_os = "haiku" ) ) ) ] //RedoxFS does not support passwd
2906
+ #[ cfg( not( target_os = "redox" ) ) ] //RedoxFS does not support passwd
2904
2907
impl From <& libc:: passwd> for User {
2905
2908
fn from( pw: & libc:: passwd) -> User {
2906
2909
unsafe {
@@ -2915,18 +2918,21 @@ impl From<&libc::passwd> for User {
2915
2918
gid: Gid :: from_raw( ( * pw) . pw_gid) ,
2916
2919
#[ cfg( not( any( target_os = "android" ,
2917
2920
target_os = "fuchsia" ,
2921
+ target_os = "haiku" ,
2918
2922
target_os = "illumos" ,
2919
2923
target_os = "linux" ,
2920
2924
target_os = "solaris" ) ) ) ]
2921
2925
class: CString :: new( CStr :: from_ptr( ( * pw) . pw_class) . to_bytes( ) ) . unwrap( ) ,
2922
2926
#[ cfg( not( any( target_os = "android" ,
2923
2927
target_os = "fuchsia" ,
2928
+ target_os = "haiku" ,
2924
2929
target_os = "illumos" ,
2925
2930
target_os = "linux" ,
2926
2931
target_os = "solaris" ) ) ) ]
2927
2932
change: ( * pw) . pw_change,
2928
2933
#[ cfg( not( any( target_os = "android" ,
2929
2934
target_os = "fuchsia" ,
2935
+ target_os = "haiku" ,
2930
2936
target_os = "illumos" ,
2931
2937
target_os = "linux" ,
2932
2938
target_os = "solaris" ) ) ) ]
@@ -2936,7 +2942,7 @@ impl From<&libc::passwd> for User {
2936
2942
}
2937
2943
}
2938
2944
2939
- #[ cfg( not( any ( target_os = "redox" , target_os = "haiku" ) ) ) ] // RedoxFS does not support passwd
2945
+ #[ cfg( not( target_os = "redox" ) ) ] // RedoxFS does not support passwd
2940
2946
impl From <User > for libc:: passwd {
2941
2947
fn from( u: User ) -> Self {
2942
2948
let name = match CString :: new( u. name) {
@@ -2962,18 +2968,21 @@ impl From<User> for libc::passwd {
2962
2968
pw_gid: u. gid. 0 ,
2963
2969
#[ cfg( not( any( target_os = "android" ,
2964
2970
target_os = "fuchsia" ,
2971
+ target_os = "haiku" ,
2965
2972
target_os = "illumos" ,
2966
2973
target_os = "linux" ,
2967
2974
target_os = "solaris" ) ) ) ]
2968
2975
pw_class: u. class. into_raw( ) ,
2969
2976
#[ cfg( not( any( target_os = "android" ,
2970
2977
target_os = "fuchsia" ,
2978
+ target_os = "haiku" ,
2971
2979
target_os = "illumos" ,
2972
2980
target_os = "linux" ,
2973
2981
target_os = "solaris" ) ) ) ]
2974
2982
pw_change: u. change,
2975
2983
#[ cfg( not( any( target_os = "android" ,
2976
2984
target_os = "fuchsia" ,
2985
+ target_os = "haiku" ,
2977
2986
target_os = "illumos" ,
2978
2987
target_os = "linux" ,
2979
2988
target_os = "solaris" ) ) ) ]
@@ -2988,7 +2997,7 @@ impl From<User> for libc::passwd {
2988
2997
}
2989
2998
}
2990
2999
2991
- #[ cfg( not( any ( target_os = "redox" , target_os = "haiku" ) ) ) ] // RedoxFS does not support passwd
3000
+ #[ cfg( not( target_os = "redox" ) ) ] // RedoxFS does not support passwd
2992
3001
impl User {
2993
3002
fn from_anything<F >( f: F ) -> Result <Option <Self >>
2994
3003
where
0 commit comments