mirror of
https://git.proxmox.com/git/proxmox
synced 2025-08-11 13:33:07 +00:00
sys: enable CreateOptions::group_root/root_only
nix now has the required const fns Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
d3364e07fb
commit
b84446a030
@ -85,12 +85,8 @@ impl CreateOptions {
|
|||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: once 'nix' has `const fn` constructors for Uid and Gid we can enable these:
|
|
||||||
|
|
||||||
/*
|
|
||||||
/// Convenience shortcut around having to import `Gid` from nix.
|
/// Convenience shortcut around having to import `Gid` from nix.
|
||||||
pub const fn group_root(self) -> Self {
|
pub const fn group_root(self) -> Self {
|
||||||
// nix hasn't constified these yet, but it's just an alias to gid_t:
|
|
||||||
self.group(Gid::from_raw(0))
|
self.group(Gid::from_raw(0))
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -98,7 +94,6 @@ impl CreateOptions {
|
|||||||
pub const fn root_only(self) -> Self {
|
pub const fn root_only(self) -> Self {
|
||||||
self.owner_root().group_root()
|
self.owner_root().group_root()
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Information about a mounted file system from statfs64 syscall
|
/// Information about a mounted file system from statfs64 syscall
|
||||||
|
Loading…
Reference in New Issue
Block a user