Skip to content

Commit 3a04c32

Browse files
committed
Auto merge of #1088 - m-hilgendorf:patch-1, r=alexcrichton
Add ftok on MacOS Provide a symbol for the `ftok` function declared in sys/ipc.h, for completeness and to allow calling `ftok` to generate the key value for `shmat`.
2 parents 4a1bae2 + f1d56f6 commit 3a04c32

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/unix/bsd/apple/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2350,6 +2350,7 @@ extern {
23502350
pub fn mprotect(addr: *mut ::c_void, len: ::size_t, prot: ::c_int)
23512351
-> ::c_int;
23522352
pub fn shm_open(name: *const ::c_char, oflag: ::c_int, ...) -> ::c_int;
2353+
pub fn ftok(pathname : *const c_char, proj_id : ::c_int) -> key_t;
23532354
pub fn shmat(shmid: ::c_int, shmaddr: *const ::c_void,
23542355
shmflg: ::c_int) -> *mut ::c_void;
23552356
pub fn shmdt(shmaddr: *const ::c_void) -> ::c_int;

0 commit comments

Comments
 (0)