path: root/api
diff options
authorBharata B Rao <>2013-11-15 10:11:58 +0530
committerAnand Avati <>2013-11-14 23:29:48 -0800
commit884a668a9c3e12e17d64ebd5ccd9fbf3d203fd1e (patch)
tree844b79ba52702c630f439d45703ee59136de356a /api
parentf21cefed298ba21f4739d6ab4ceea81b97d2aab8 (diff)
zerofill: Change the type of len argument of glfs_zerofill() to off_t
glfs_zerofill() can be potentially called to zero-out entire file and hence allow for bigger value of length parameter. Change-Id: I75f1d11af298915049a3f3a7cb3890a2d72fca63 BUG: 1028673 Signed-off-by: Bharata B Rao <> Reviewed-on: Tested-by: Gluster Build System <> Reviewed-by: M. Mohan Kumar <> Tested-by: M. Mohan Kumar <> Reviewed-by: Anand Avati <>
Diffstat (limited to 'api')
2 files changed, 4 insertions, 4 deletions
diff --git a/api/src/glfs-fops.c b/api/src/glfs-fops.c
index 10bb7d38b..93c5101a0 100644
--- a/api/src/glfs-fops.c
+++ b/api/src/glfs-fops.c
@@ -1877,7 +1877,7 @@ glfs_discard_async (struct glfs_fd *glfd, off_t offset, size_t len,
-glfs_zerofill_async (struct glfs_fd *glfd, off_t offset, size_t len,
+glfs_zerofill_async (struct glfs_fd *glfd, off_t offset, off_t len,
glfs_io_cbk fn, void *data)
struct glfs_io *gio = NULL;
@@ -2927,7 +2927,7 @@ out:
-glfs_zerofill (struct glfs_fd *glfd, off_t offset, size_t len)
+glfs_zerofill (struct glfs_fd *glfd, off_t offset, off_t len)
int ret = -1;
xlator_t *subvol = NULL;
diff --git a/api/src/glfs.h b/api/src/glfs.h
index 18fda496e..bf298ce47 100644
--- a/api/src/glfs.h
+++ b/api/src/glfs.h
@@ -556,9 +556,9 @@ int glfs_discard(glfs_fd_t *fd, off_t offset, size_t len);
int glfs_discard_async (glfs_fd_t *fd, off_t length, size_t lent,
glfs_io_cbk fn, void *data);
-int glfs_zerofill(glfs_fd_t *fd, off_t offset, size_t len);
+int glfs_zerofill(glfs_fd_t *fd, off_t offset, off_t len);
-int glfs_zerofill_async (glfs_fd_t *fd, off_t length, size_t len,
+int glfs_zerofill_async (glfs_fd_t *fd, off_t length, off_t len,
glfs_io_cbk fn, void *data);
char *glfs_getcwd (glfs_t *fs, char *buf, size_t size);