summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra G <raghavendra@gluster.com>2011-07-06 08:38:37 +0000
committerAnand Avati <avati@gluster.com>2011-07-12 06:59:48 -0700
commit4760abc45b7f01aa6f0c867b55b1bbfc6164be5f (patch)
treeed4cbc4b268b7dc2b52911e289206ee7cc26c7c2
parentc6176b1516c2d6a9dfbdc4b769a90f8c24b0a595 (diff)
mnt/fuse: generate uuids in fuse_lookup, not in fuse_lookup_resume.
Signed-off-by: Raghavendra G <raghavendra@gluster.com> Signed-off-by: Anand Avati <avati@gluster.com> BUG: 3041 ([glusterfs-3.1.5qa2]: stat gives EINVAL) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=3041
-rw-r--r--xlators/mount/fuse/src/fuse-bridge.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/mount/fuse/src/fuse-bridge.c b/xlators/mount/fuse/src/fuse-bridge.c
index 8ab8f82..73a11f8 100644
--- a/xlators/mount/fuse/src/fuse-bridge.c
+++ b/xlators/mount/fuse/src/fuse-bridge.c
@@ -251,7 +251,6 @@ fuse_lookup_resume (fuse_state_t *state)
gf_log ("glusterfs-fuse", GF_LOG_TRACE,
"%"PRIu64": LOOKUP %s", state->finh->unique,
state->loc.path);
- uuid_generate (state->gfid);
state->loc.inode = inode_new (state->loc.parent->table);
}
@@ -280,6 +279,8 @@ fuse_lookup (xlator_t *this, fuse_in_header_t *finh, void *msg)
if (state->loc.inode) {
uuid_copy (state->resolve.gfid, state->loc.inode->gfid);
+ } else {
+ uuid_generate (state->gfid);
}
uuid_copy (state->resolve.pargfid, state->loc.parent->gfid);