aboutsummaryrefslogtreecommitdiffhomepage
path: root/oxish/src/server.rs
diff options
context:
space:
mode:
Diffstat (limited to 'oxish/src/server.rs')
-rw-r--r--oxish/src/server.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/oxish/src/server.rs b/oxish/src/server.rs
index 8d76a7d..2a0a472 100644
--- a/oxish/src/server.rs
+++ b/oxish/src/server.rs
@@ -243,6 +243,9 @@ impl Server {
let mut groups = vec![0; count as usize];
loop {
#[allow(trivial_numeric_casts)] // platform dependent
+ // SAFETY: `name` is a valid null-terminated C string, and `groups` and `count`
+ // describe a live allocation with capacity for `count` entries; `count` is valid
+ // for writes.
let ret = unsafe {
libc::getgrouplist(
name.as_ptr(),