File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -249,10 +249,17 @@ impl SockProtocol {
249249 pub const KextEvent : SockProtocol = SockProtocol :: Icmp ; // Matches libc::SYSPROTO_EVENT
250250
251251 /// Packet filter on IPv4 traffic
252- /// NOTE: placed here due to conflict (little endian arch) with SockProtocol::NetLinkISCI
252+ // NOTE: placed here due to conflict (little endian arch) with SockProtocol::NetLinkISCI
253253 #[ cfg( linux_android) ]
254254 #[ allow( non_upper_case_globals) ]
255+ #[ cfg( target_endian = "little" ) ]
255256 pub const EthIp : SockProtocol = unsafe { std:: mem:: transmute :: < i32 , SockProtocol > ( ( libc:: ETH_P_IP as u16 ) . to_be ( ) as i32 ) } ;
257+
258+ /// Packet filter on IPv4 traffic
259+ #[ cfg( linux_android) ]
260+ #[ allow( non_upper_case_globals) ]
261+ #[ cfg( target_endian = "big" ) ]
262+ pub const EthIp : i32 = ( libc:: ETH_P_IP as u16 ) . to_be ( ) as i32 ;
256263}
257264#[ cfg( linux_android) ]
258265libc_bitflags ! {
You can’t perform that action at this time.
0 commit comments