proxmox-shared-memory: fix nix 0.24 compat in test

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
Fabian Grünbichler 2022-06-02 11:58:46 +02:00
parent abf5aedc54
commit f8b19c2e22

View File

@ -88,7 +88,7 @@ fn create_test_dir<T: Init>(filename: &str) -> Option<PathBuf> {
let oflag = OFlag::O_RDWR | OFlag::O_CLOEXEC;
// check for O_TMPFILE support
if let Err(nix::Error::Sys(nix::errno::Errno::EOPNOTSUPP)) = nix::fcntl::open(
if let Err(nix::errno::Errno::EOPNOTSUPP) = nix::fcntl::open(
path.parent().unwrap(),
oflag | OFlag::O_TMPFILE,
Mode::empty(),