Skip to content

Commit 49e6255

Browse files
committed
Auto merge of #2542 - devnexen:ftok_nbsd_obsd, r=JohnTitor
netbsd/openbsd ftok addition.
2 parents 9d94fb1 + c42379d commit 49e6255

File tree

4 files changed

+5
-0
lines changed

4 files changed

+5
-0
lines changed

libc-test/build.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,7 @@ fn test_openbsd(target: &str) {
430430
"string.h",
431431
"sys/file.h",
432432
"sys/ioctl.h",
433+
"sys/ipc.h",
433434
"sys/mman.h",
434435
"sys/param.h",
435436
"sys/resource.h",
@@ -993,6 +994,7 @@ fn test_netbsd(target: &str) {
993994
"sys/file.h",
994995
"sys/ioctl.h",
995996
"sys/ioctl_compat.h",
997+
"sys/ipc.h",
996998
"sys/ktrace.h",
997999
"sys/mman.h",
9981000
"sys/mount.h",

libc-test/semver/netbsd.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1183,6 +1183,7 @@ forkpty
11831183
freeifaddrs
11841184
freelocale
11851185
fsid_t
1186+
ftok
11861187
futimes
11871188
getbootfile
11881189
getbyteorder

libc-test/semver/openbsd.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -952,6 +952,7 @@ freelocale
952952
freezero
953953
fsid_t
954954
fstatfs
955+
ftok
955956
fusefs_args
956957
futimes
957958
getdomainname

src/unix/bsd/netbsdlike/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -747,6 +747,7 @@ extern "C" {
747747
pub fn reallocarray(ptr: *mut ::c_void, nmemb: ::size_t, size: ::size_t) -> *mut ::c_void;
748748
pub fn gethostid() -> ::c_long;
749749
pub fn sethostid(hostid: ::c_long) -> ::c_int;
750+
pub fn ftok(path: *const ::c_char, id: ::c_int) -> ::key_t;
750751
}
751752

752753
cfg_if! {

0 commit comments

Comments
 (0)