Skip to content

Commit

Permalink
Add getentropy for Emscripten
Browse files Browse the repository at this point in the history
  • Loading branch information
kleisauke committed Jan 23, 2023
1 parent f7b4c2e commit 2fb7a4a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/unix/linux_like/emscripten/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1814,7 +1814,6 @@ extern "C" {
) -> ::c_int;
pub fn getloadavg(loadavg: *mut ::c_double, nelem: ::c_int) -> ::c_int;

// Not available now on Android
pub fn mkfifoat(dirfd: ::c_int, pathname: *const ::c_char, mode: ::mode_t) -> ::c_int;
pub fn if_nameindex() -> *mut if_nameindex;
pub fn if_freenameindex(ptr: *mut if_nameindex);
Expand Down Expand Up @@ -1882,6 +1881,8 @@ extern "C" {
f: extern "C" fn(*mut ::c_void) -> *mut ::c_void,
value: *mut ::c_void,
) -> ::c_int;

pub fn getentropy(buf: *mut ::c_void, buflen: ::size_t) -> ::c_int;
}

cfg_if! {
Expand Down

0 comments on commit 2fb7a4a

Please sign in to comment.