From f44ada6cd9bcc5ab98ca66bedde4fe23dd1c3f05 Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Sun, 14 Apr 2013 02:58:34 -0700 Subject: gfapi: support for chdir() and family Add support for chdir, fchdir, getcwd, realpath equivalents in GFAPI. These are required for the Samba VFS plugin. Change-Id: I91d2db9146994403c98961c489c7640c51d5add2 BUG: 953694 Signed-off-by: Anand Avati Reviewed-on: http://review.gluster.org/5151 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- api/src/glfs-internal.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'api/src/glfs-internal.h') diff --git a/api/src/glfs-internal.h b/api/src/glfs-internal.h index c2fc0ecc1..082b8fa5c 100644 --- a/api/src/glfs-internal.h +++ b/api/src/glfs-internal.h @@ -36,9 +36,12 @@ struct glfs { char *oldvolfile; ssize_t oldvollen; + + inode_t *cwd; }; struct glfs_fd { + struct glfs *fs; off_t offset; fd_t *fd; struct list_head entries; @@ -75,6 +78,8 @@ __glfs_entry_fd (struct glfs_fd *fd) void glfs_fd_destroy (struct glfs_fd *glfd); +struct glfs_fd *glfs_fd_new (struct glfs *fs); + xlator_t * glfs_fd_subvol (struct glfs_fd *glfd); xlator_t * glfs_active_subvol (struct glfs *fs); -- cgit