summaryrefslogtreecommitdiffstats
path: root/xlators/storage
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/storage')
-rw-r--r--xlators/storage/posix/src/posix-handle.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/xlators/storage/posix/src/posix-handle.c b/xlators/storage/posix/src/posix-handle.c
index 5d184d930b0..2bf8813f44c 100644
--- a/xlators/storage/posix/src/posix-handle.c
+++ b/xlators/storage/posix/src/posix-handle.c
@@ -176,6 +176,10 @@ posix_make_ancestryfromgfid (xlator_t *this, char *path, int pathsize,
memset (&iabuf, 0, sizeof (iabuf));
inode = posix_resolve (this, itable, *parent, dir_name, &iabuf);
+ if (inode == NULL) {
+ ret = -1;
+ goto out;
+ }
strcat (dir_name, "/");
ret = posix_make_ancestral_node (priv_base_path, path, pathsize, head,