We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c9c82df commit c6452d3Copy full SHA for c6452d3
src/wasi.rs
@@ -14,7 +14,7 @@ pub fn getrandom_inner(dest: &mut [u8]) -> Result<(), Error> {
14
let ret =
15
unsafe { libc::__wasi_random_get(dest.as_mut_ptr() as *mut libc::c_void, dest.len()) };
16
if let Some(code) = NonZeroU32::new(ret as u32) {
17
- error!("WASI: __wasi_random_get: failed with {}", errno);
+ error!("WASI: __wasi_random_get: failed with {}", ret);
18
Err(Error::from(code))
19
} else {
20
Ok(()) // Zero means success for WASI
0 commit comments