diff options
author | Shehjar Tikoo <shehjart@zresearch.com> | 2009-05-05 15:59:03 +0530 |
---|---|---|
committer | Anand V. Avati <avati@amp.gluster.com> | 2009-05-05 17:36:23 +0530 |
commit | 7eb61fb44986fc834a19d9f38754f1be54d07e09 (patch) | |
tree | db9da47c2db9edd592b929dd2ae935ee519fac41 /libglusterfsclient/src/libglusterfsclient.h | |
parent | b48df70c58f52878d58f3e1a0adc870688cdfcdc (diff) |
libglusterfsclient: Conform'ify glusterfs_readdir
This commit does two things:
1. Changes glusterfs_readdir prototype to conform to the POSIX
readdir().
2. Uses a 1024-byte value instead of sizeof(struct dirent) for the
@size for libgf_client_readdir. This allows even larger names to fit
into a single readdir request to the server.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
Diffstat (limited to 'libglusterfsclient/src/libglusterfsclient.h')
-rwxr-xr-x | libglusterfsclient/src/libglusterfsclient.h | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/libglusterfsclient/src/libglusterfsclient.h b/libglusterfsclient/src/libglusterfsclient.h index ae0d86a0e64..1c2441b2b14 100755 --- a/libglusterfsclient/src/libglusterfsclient.h +++ b/libglusterfsclient/src/libglusterfsclient.h @@ -607,15 +607,12 @@ glusterfs_rmdir (const char *path); * * @fd : The handle of the directory to be read. This handle * is the one returned by opendir. - * @dirp : The pointer to the array of directory entries into - * which the directory data will be stored. - * @count : Number of directory entries to be read. * - * Returns 0 on success and -1 on error with errno set appropriately. + * Returns the directory entry on success and NULL pointer on error + * with errno set appropriately. */ -int -glusterfs_readdir (glusterfs_dir_t fd, struct dirent *dirp, - unsigned int count); +struct dirent * +glusterfs_readdir (glusterfs_dir_t dirfd); |