mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 10:28:47 +00:00
copy_file: ioctl_ficlone EACCES, EPERM as not supported. (#8425)
ioctl_ficlone may return EPERM (in LXC container), EACCESS (in Android). Those error should be taken as ficlone being not supported instead of error. Refer to this coreutils bug report https://bugs.gnu.org/62404
This commit is contained in:
@@ -52,10 +52,9 @@ pub fn copyFile(in: InputType, out: InputType) CopyFileError!void {
|
||||
.NOMEM => return error.OutOfMemory,
|
||||
.NOSPC => return error.NoSpaceLeft,
|
||||
.OVERFLOW => return error.Unseekable,
|
||||
.PERM => return error.PermissionDenied,
|
||||
.TXTBSY => return error.FileBusy,
|
||||
.XDEV => {},
|
||||
.BADF, .INVAL, .OPNOTSUPP, .NOSYS => {
|
||||
.ACCES, .BADF, .INVAL, .OPNOTSUPP, .NOSYS, .PERM => {
|
||||
bun.Output.debug("ioctl_ficlonerange is NOT supported", .{});
|
||||
can_use_ioctl_ficlone_.store(-1, .Monotonic);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user