diff options
author | Anand Avati <avati@redhat.com> | 2014-03-27 23:53:58 -0700 |
---|---|---|
committer | Anand Avati <avati@redhat.com> | 2014-04-20 18:07:11 -0700 |
commit | bac02a359f86a742fbf750cf4f056160324d0746 (patch) | |
tree | 614039efd4e64f78002cba32bc86b5ec9eaab64c /xlators/mount | |
parent | a67630b3970f9ad035a1d1463d9c2a6c6e7de736 (diff) |
fuse-resolve: loc_wipe() after inode_link()
the inode to be linked may have the last ref. loc_wipe() can
destroy it before inode_link() gets to ref it.
Change-Id: Ic2d44084e6e9c8289f35cae82c8e4575af105398
BUG: 1089216
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.org/7505
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Diffstat (limited to 'xlators/mount')
-rw-r--r-- | xlators/mount/fuse/src/fuse-resolve.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xlators/mount/fuse/src/fuse-resolve.c b/xlators/mount/fuse/src/fuse-resolve.c index 17d76d46bb1..76b1d9a72cc 100644 --- a/xlators/mount/fuse/src/fuse-resolve.c +++ b/xlators/mount/fuse/src/fuse-resolve.c @@ -163,10 +163,10 @@ fuse_resolve_gfid_cbk (call_frame_t *frame, void *cookie, xlator_t *this, goto out; } - loc_wipe (&resolve->resolve_loc); - link_inode = inode_link (inode, NULL, NULL, buf); + loc_wipe (&resolve->resolve_loc); + if (!link_inode) goto out; |