-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cp(file,file-copy) broken for >2GB files #14574
Comments
Yes, there is a 32-bit problem. The return value (indicating the number of bytes written) is restricted to function sendfile(dst::File, src::File, src_offset::Int64, bytes::Int)
check_open(dst)
check_open(src)
err = ccall(:jl_fs_sendfile, Int32, (Int32, Int32, Int64, Csize_t),
src.handle, dst.handle, src_offset, bytes)
uv_error("sendfile", err)
nothing
end |
OK... I guess that's unfortunate. Do you think we should modify |
we should probably have |
Has there been any progress on this issue? I am running into this problem when running on Linux. However, |
@vtjnash: did we ever find/file and upstream libuv bug here? Any chance that you can use your newly earned libuv commit bit to find and fix this issue there? |
The upstream issues are fixed (recently), but that usage looks possibly wrong too (doesn't handle partial writes). We can also just switch to using the new API (
Theoretically yes, but in practice, most kernels won't accept writes bigger than 31-bits either. |
It seems to me we should do both: call |
workaround for JuliaLang/julia#14574.
Please fix! |
Hello,
I'm not sure if this is an issue with my installation, but the
cp
function is not working for files larger than 2GB:The following code:
produces:
I guess it might be a 32bit file pointer issue, so I thought I should also note that on my install, I see:
sizeof(Int)=8
.Here's the rest of
versioninfo()
:Thanks!
Sam
The text was updated successfully, but these errors were encountered: