Skip to content

Commit

Permalink
this can be null
Browse files Browse the repository at this point in the history
  • Loading branch information
jupyterkat committed May 9, 2024
1 parent 97c15a9 commit 83ae193
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions crates/byondapi-rs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ pub unsafe fn parse_args(
argc: byondapi_sys::u4c,
argv: *mut ByondValue,
) -> &'static mut [ByondValue] {
if argv.is_null() {
return &[];
}
unsafe { std::slice::from_raw_parts_mut(argv, argc as usize) }
}

Expand Down

0 comments on commit 83ae193

Please sign in to comment.