@@ -1129,6 +1129,15 @@ s! {
11291129 pub validattr: attribute_set_t,
11301130 pub nativeattr: attribute_set_t,
11311131 }
1132+
1133+ #[ cfg_attr( libc_packedN, repr( packed( 4 ) ) ) ]
1134+ pub struct ifconf {
1135+ pub ifc_len: :: c_int,
1136+ #[ cfg( libc_union) ]
1137+ pub ifc_ifcu: __c_anonymous_ifc_ifcu,
1138+ #[ cfg( not( libc_union) ) ]
1139+ pub ifc_ifcu: * mut ifreq,
1140+ }
11321141}
11331142
11341143s_no_extra_traits ! {
@@ -1467,6 +1476,12 @@ s_no_extra_traits! {
14671476 #[ cfg( not( libc_union) ) ]
14681477 pub ifr_ifru: :: sockaddr,
14691478 }
1479+
1480+ #[ cfg( libc_union) ]
1481+ pub union __c_anonymous_ifc_ifcu {
1482+ pub ifcu_buf: * mut :: c_char,
1483+ pub ifcu_req: * mut ifreq,
1484+ }
14701485}
14711486
14721487impl siginfo_t {
@@ -3000,6 +3015,37 @@ cfg_if! {
30003015 self . ifr_ifru. hash( state) ;
30013016 }
30023017 }
3018+
3019+ #[ cfg( libc_union) ]
3020+ impl Eq for __c_anonymous_ifc_ifcu { }
3021+
3022+ #[ cfg( libc_union) ]
3023+ impl PartialEq for __c_anonymous_ifc_ifcu {
3024+ fn eq( & self , other: & __c_anonymous_ifc_ifcu) -> bool {
3025+ unsafe {
3026+ self . ifcu_buf == other. ifcu_buf &&
3027+ self . ifcu_req == other. ifcu_req
3028+ }
3029+ }
3030+ }
3031+
3032+ #[ cfg( libc_union) ]
3033+ impl :: fmt:: Debug for __c_anonymous_ifc_ifcu {
3034+ fn fmt( & self , f: & mut :: fmt:: Formatter ) -> :: fmt:: Result {
3035+ f. debug_struct( "ifc_ifcu" )
3036+ . field( "ifcu_buf" , unsafe { & self . ifcu_buf } )
3037+ . field( "ifcu_req" , unsafe { & self . ifcu_req } )
3038+ . finish( )
3039+ }
3040+ }
3041+
3042+ #[ cfg( libc_union) ]
3043+ impl :: hash:: Hash for __c_anonymous_ifc_ifcu {
3044+ fn hash<H : :: hash:: Hasher >( & self , state: & mut H ) {
3045+ unsafe { self . ifcu_buf. hash( state) } ;
3046+ unsafe { self . ifcu_req. hash( state) } ;
3047+ }
3048+ }
30033049 }
30043050}
30053051
0 commit comments