Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/aienux/blob/main/vendor/getrandom/src/fuchsia.rs # aienux Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `aienux / vendor / getrandom / src / fuchsia.rs` 13 lines ยท 340 bytes Raw Blame History 1 //! Implementation for Fuchsia Zircon 2 use crate::Error; 3 use core::mem::MaybeUninit; 4 5 #[link(name = "zircon")] 6 extern "C" { 7 fn zx_cprng_draw(buffer: *mut u8, length: usize); 8 } 9 10 pub fn getrandom_inner(dest: &mut [MaybeUninit]) -> Result<(), Error> { 11 unsafe { zx_cprng_draw(dest.as_mut_ptr() as *mut u8, dest.len()) } 12 Ok(()) 13 }