summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Lau <stevelauc@outlook.com>2022-10-09 18:25:49 +0800
committerSteve Lau <stevelauc@outlook.com>2022-10-09 18:25:49 +0800
commita36515f3f3255a76c6bebc28faf9709bb15d4323 (patch)
tree5a40ab1cdedbc377b4924330ecbdd0c933af6a5a
parent8dcd55656eb7abbef1d6cfeb8bad28306473fce6 (diff)
downloadrust-libc-a36515f3f3255a76c6bebc28faf9709bb15d4323.tar.gz
add eaccess on freebsd and dragonfly
-rw-r--r--libc-test/semver/dragonfly.txt1
-rw-r--r--libc-test/semver/freebsd.txt1
-rw-r--r--src/unix/bsd/freebsdlike/mod.rs2
3 files changed, 4 insertions, 0 deletions
diff --git a/libc-test/semver/dragonfly.txt b/libc-test/semver/dragonfly.txt
index e56441640b..e27f0f6fda 100644
--- a/libc-test/semver/dragonfly.txt
+++ b/libc-test/semver/dragonfly.txt
@@ -1536,3 +1536,4 @@ vmspace
wait4
waitid
xucred
+eaccess \ No newline at end of file
diff --git a/libc-test/semver/freebsd.txt b/libc-test/semver/freebsd.txt
index e74355f1e5..649ef77161 100644
--- a/libc-test/semver/freebsd.txt
+++ b/libc-test/semver/freebsd.txt
@@ -1925,3 +1925,4 @@ wait4
waitid
xallocx
xucred
+eaccess \ No newline at end of file
diff --git a/src/unix/bsd/freebsdlike/mod.rs b/src/unix/bsd/freebsdlike/mod.rs
index 3bf083c5ca..db21597d98 100644
--- a/src/unix/bsd/freebsdlike/mod.rs
+++ b/src/unix/bsd/freebsdlike/mod.rs
@@ -1731,6 +1731,8 @@ extern "C" {
pub fn eui64_ntoa(id: *const eui64, a: *mut ::c_char, len: ::size_t) -> ::c_int;
pub fn eui64_ntohost(hostname: *mut ::c_char, len: ::size_t, id: *const eui64) -> ::c_int;
pub fn eui64_hostton(hostname: *const ::c_char, id: *mut eui64) -> ::c_int;
+
+ pub fn eaccess(path: *const ::c_char, mode: ::c_int) -> ::c_int;
}
#[link(name = "rt")]