mirror of
https://github.com/uutils/coreutils.git
synced 2025-12-23 08:47:37 +00:00
Merge pull request #8641 from maxfilov/main
Replace casting to Ioctl with a const from libc
This commit is contained in:
commit
a6d782fd05
1 changed files with 1 additions and 2 deletions
|
|
@ -62,8 +62,7 @@ where
|
|||
let dst_file = File::create(&dest)?;
|
||||
let src_fd = src_file.as_raw_fd();
|
||||
let dst_fd = dst_file.as_raw_fd();
|
||||
let result =
|
||||
unsafe { libc::ioctl(dst_fd, linux_raw_sys::ioctl::FICLONE as libc::Ioctl, src_fd) };
|
||||
let result = unsafe { libc::ioctl(dst_fd, libc::FICLONE, src_fd) };
|
||||
if result == 0 {
|
||||
return Ok(());
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue