Deprecate ENOATTR on Linux and Android
This commit is contained in:
parent
eea0102308
commit
4774fc1c9f
|
@ -1379,6 +1379,12 @@ fn test_android(target: &str) {
|
|||
// FIXME: deprecated: not available in any header
|
||||
// See: https://github.com/rust-lang/libc/issues/1356
|
||||
"ENOATTR" => true,
|
||||
|
||||
// FIXME: still necessary?
|
||||
"SIG_DFL" | "SIG_ERR" | "SIG_IGN" => true, // sighandler_t weirdness
|
||||
// FIXME: still necessary?
|
||||
"SIGUNUSED" => true, // removed in glibc 2.26
|
||||
|
||||
_ => false,
|
||||
}
|
||||
});
|
||||
|
|
|
@ -1792,7 +1792,10 @@ pub const SIOCSIFMAP: ::c_ulong = 0x00008971;
|
|||
pub const MODULE_INIT_IGNORE_MODVERSIONS: ::c_uint = 0x0001;
|
||||
pub const MODULE_INIT_IGNORE_VERMAGIC: ::c_uint = 0x0002;
|
||||
|
||||
// Similarity to Linux it's not used but defined for compatibility.
|
||||
#[deprecated(
|
||||
since = "0.2.55",
|
||||
note = "ENOATTR is not available on Android; use ENODATA instead"
|
||||
)]
|
||||
pub const ENOATTR: ::c_int = ::ENODATA;
|
||||
|
||||
// linux/if_alg.h
|
||||
|
|
|
@ -1409,9 +1409,10 @@ pub const FALLOC_FL_ZERO_RANGE: ::c_int = 0x10;
|
|||
pub const FALLOC_FL_INSERT_RANGE: ::c_int = 0x20;
|
||||
pub const FALLOC_FL_UNSHARE_RANGE: ::c_int = 0x40;
|
||||
|
||||
// On Linux, libc doesn't define this constant, libattr does instead.
|
||||
// We still define it for Linux as it's defined by libc on other platforms,
|
||||
// and it's mentioned in the man pages for getxattr and setxattr.
|
||||
#[deprecated(
|
||||
since = "0.2.55",
|
||||
note = "ENOATTR is not available on Linux; use ENODATA instead"
|
||||
)]
|
||||
pub const ENOATTR: ::c_int = ::ENODATA;
|
||||
|
||||
pub const SO_ORIGINAL_DST: ::c_int = 80;
|
||||
|
|
Loading…
Reference in New Issue