File tree 3 files changed +5
-4
lines changed
3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change
1
+ Add socket option IP_TOS (nix::sys::socket::sockopt::IpTos) IPV6_TCLASS (nix::sys::socket::sockopt::Ipv6TClass) on Android/FreeBSD
Original file line number Diff line number Diff line change @@ -402,7 +402,7 @@ sockopt_impl!(
402
402
libc:: SO_PRIORITY ,
403
403
libc:: c_int
404
404
) ;
405
- #[ cfg( target_os = "linux" ) ]
405
+ #[ cfg( any ( linux_android , target_os = "freebsd" ) ) ]
406
406
#[ cfg( feature = "net" ) ]
407
407
sockopt_impl ! (
408
408
#[ cfg_attr( docsrs, doc( cfg( feature = "net" ) ) ) ]
@@ -414,7 +414,7 @@ sockopt_impl!(
414
414
libc:: IP_TOS ,
415
415
libc:: c_int
416
416
) ;
417
- #[ cfg( target_os = "linux" ) ]
417
+ #[ cfg( any ( linux_android , target_os = "freebsd" ) ) ]
418
418
#[ cfg( feature = "net" ) ]
419
419
sockopt_impl ! (
420
420
#[ cfg_attr( docsrs, doc( cfg( feature = "net" ) ) ) ]
Original file line number Diff line number Diff line change @@ -469,7 +469,7 @@ fn test_so_priority() {
469
469
}
470
470
471
471
#[ test]
472
- #[ cfg( target_os = "linux" ) ]
472
+ #[ cfg( any ( linux_android , target_os = "freebsd" ) ) ]
473
473
fn test_ip_tos ( ) {
474
474
let fd = socket (
475
475
AddressFamily :: Inet ,
@@ -484,7 +484,7 @@ fn test_ip_tos() {
484
484
}
485
485
486
486
#[ test]
487
- #[ cfg( target_os = "linux" ) ]
487
+ #[ cfg( any ( linux_android , target_os = "freebsd" ) ) ]
488
488
// Disable the test under emulation because it fails in Cirrus-CI. Lack
489
489
// of QEMU support is suspected.
490
490
#[ cfg_attr( qemu, ignore) ]
You can’t perform that action at this time.
0 commit comments