From c6bdbfebd5eba9889b9138a7294319da0ba2c526 Mon Sep 17 00:00:00 2001 From: Mike Nolta Date: Fri, 14 Nov 2014 13:27:12 -0500 Subject: [PATCH] fix jl_fs_write type sig uv_fs_write:offset is int64_t, not size_t. Closes nolta/Winston.jl#182. --- base/fs.jl | 2 +- src/jl_uv.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/base/fs.jl b/base/fs.jl index c44dd47272d3a..1e9cb80b9734d 100644 --- a/base/fs.jl +++ b/base/fs.jl @@ -171,7 +171,7 @@ function write(f::File, buf::Ptr{UInt8}, len::Integer, offset::Integer=-1) if !f.open error("file is not open") end - err = ccall(:jl_fs_write, Int32, (Int32, Ptr{UInt8}, Csize_t, Csize_t), + err = ccall(:jl_fs_write, Int32, (Int32, Ptr{UInt8}, Csize_t, Int64), f.handle, buf, len, offset) uv_error("write",err) len diff --git a/src/jl_uv.c b/src/jl_uv.c index 9d9c94dfb96a2..37615cbd156c8 100644 --- a/src/jl_uv.c +++ b/src/jl_uv.c @@ -452,7 +452,7 @@ DLLEXPORT int jl_fs_chmod(char *path, int mode) return ret; } -DLLEXPORT int jl_fs_write(int handle, char *data, size_t len, size_t offset) +DLLEXPORT int jl_fs_write(int handle, char *data, size_t len, int64_t offset) { uv_fs_t req; uv_buf_t buf[1];