mirror of
https://gitee.com/openharmony/third_party_rust_nix
synced 2025-01-08 08:20:35 +00:00
Fix fcntl for FreeBSD
Need to use the right cfg option for the conditional compilation. target_os is the right option to use when targeting FreeBSD. target_env was used before which seems to be a typo.
This commit is contained in:
parent
8cff207a13
commit
d965259685
@ -20,7 +20,7 @@ use crate::sys::uio::IoVec; // For vmsplice
|
||||
target_os = "fuchsia",
|
||||
any(target_os = "wasi", target_env = "wasi"),
|
||||
target_env = "uclibc",
|
||||
target_env = "freebsd"
|
||||
target_os = "freebsd"
|
||||
))]
|
||||
pub use self::posix_fadvise::*;
|
||||
|
||||
@ -587,7 +587,7 @@ pub fn fallocate(
|
||||
target_os = "fuchsia",
|
||||
any(target_os = "wasi", target_env = "wasi"),
|
||||
target_env = "uclibc",
|
||||
target_env = "freebsd"
|
||||
target_os = "freebsd"
|
||||
))]
|
||||
mod posix_fadvise {
|
||||
use crate::errno::Errno;
|
||||
|
@ -332,7 +332,7 @@ mod linux_android {
|
||||
target_os = "fuchsia",
|
||||
any(target_os = "wasi", target_env = "wasi"),
|
||||
target_env = "uclibc",
|
||||
target_env = "freebsd"))]
|
||||
target_os = "freebsd"))]
|
||||
mod test_posix_fadvise {
|
||||
|
||||
use tempfile::NamedTempFile;
|
||||
|
Loading…
Reference in New Issue
Block a user