pub unsafe extern "C" fn sys_argv(
out_words: *mut u32,
out_nwords: usize,
arg_index: usize,
) -> usizeExpand description
Retrieves the argument with arg_index, and stores as much of it as it can it in the memory at [out_words, out_words + out_nwords).
Returns the length, in bytes, of the argument string. If the requested
argument index does not exist (i.e. arg_index >= argc) then this syscall
will not return.
This is normally called twice to read an argument: Once to get the length of the value, and once to fill in allocated memory.
NOTE: Repeated calls to sys_argv are not guaranteed to result in the same data being returned. Returned data is entirely in the control of the host.
ยงSafety
out_words must be aligned and dereferenceable.