Skip to content

Commit 206f8a0

Browse files
Upgrade nix to 0.30
Minor code change required due to change in fallocate signature.
1 parent 948d693 commit 206f8a0

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

xtask/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ ext4-view = { path = "../", features = ["std"] }
2121
gpt_disk_io = { version = "0.16.0", features = ["std"] }
2222
libc = "0.2.155"
2323
lzma-rs = "0.3.0"
24-
nix = { version = "0.29.0", features = ["fs", "user"] }
24+
nix = { version = "0.30.0", features = ["fs", "user"] }
2525
ovmf-prebuilt = "0.2.2"
2626
sha2 = "0.10.8"
2727
tar = "0.4.40"

xtask/src/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ use dmsetup::{DmDevice, DmFlakey};
1919
use losetup::LoopDevice;
2020
use nix::fcntl::{self, FallocateFlags};
2121
use std::fs::{self, OpenOptions};
22-
use std::os::fd::AsRawFd;
2322
use std::os::unix::fs::symlink;
2423
use std::path::{Path, PathBuf};
2524
use std::process::Command;
@@ -451,7 +450,7 @@ fn create_file_with_holes(path: &Path) -> Result<()> {
451450
let offset = block_size * block;
452451
let len = block_size * 2;
453452
fcntl::fallocate(
454-
f.as_raw_fd(),
453+
&f,
455454
FallocateFlags::FALLOC_FL_PUNCH_HOLE
456455
| FallocateFlags::FALLOC_FL_KEEP_SIZE,
457456
offset as i64,

0 commit comments

Comments
 (0)