fmt: cargo fmt
CI / check (push) Successful in 1m3s

This commit is contained in:
changchichung
2026-09-02 10:08:21 +08:00
parent d0b1688ff2
commit 45fe412098
3 changed files with 7 additions and 68 deletions
+7 -1
View File
@@ -418,7 +418,13 @@ fn get_size_via_ioctl(path: &Path) -> Result<u64, WipeError> {
let mut size: u64 = 0;
// BLKGETSIZE64 = _IOR(0x12,114,size_t) => 0x80081272 on x86_64
const BLKGETSIZE64: libc::c_ulong = 0x80081272;
let ret = unsafe { libc::ioctl(fd, BLKGETSIZE64 as _, &mut size as *mut u64 as *mut libc::c_void) };
let ret = unsafe {
libc::ioctl(
fd,
BLKGETSIZE64 as _,
&mut size as *mut u64 as *mut libc::c_void,
)
};
if ret == 0 {
Ok(size)
} else {