Remove "users" crate, call libc directly

This is all I actually needed anyways
This commit is contained in:
John Doty 2024-08-12 17:37:34 -07:00
parent 35dcf93971
commit df0ca4ce31
3 changed files with 4 additions and 13 deletions

View file

@ -55,7 +55,8 @@ fn socket_directory() -> Result<std::path::PathBuf> {
Ok(path) => Ok(path),
Err(_) => {
let mut path = std::env::temp_dir();
path.push(format!("fwd{}", users::get_current_uid()));
let uid = unsafe { libc::getuid() };
path.push(format!("fwd{}", uid));
Ok(path)
}
}