Skip to content

Commit

Permalink
Correctly handle where group name is NULL
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed Nov 26, 2023
1 parent e2a88f4 commit 2045107
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/users.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ pub(crate) unsafe fn get_group_name(
}
let g = g.assume_init();
let mut group_name = Vec::new();
if g.gr_name.is_null() {
return Some(String::new());
}
let c_group_name = g.gr_name;
let mut x = 0;
loop {
Expand Down

0 comments on commit 2045107

Please sign in to comment.