summaryrefslogtreecommitdiffstats
path: root/xlators/protocol
diff options
context:
space:
mode:
authorAnand Avati <avati@gluster.com>2010-09-28 23:04:24 +0000
committerVijay Bellur <vijay@dev.gluster.com>2010-09-28 21:54:09 -0700
commit7fa2a88a28578dce36d88436776c05aee65165fd (patch)
tree68f8c6640ea1327c873cdb2a037ff67011e086b4 /xlators/protocol
parent6686ddc22785fba5ea488fcaafa598161469085b (diff)
resolver: set safer conditionals during path creation
when client would send just the path as part of a transaction, path reconstruction would create parent directory's path instead of actual path at the time of resolution. Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 935 (Directories change mode from 0755 to 0644 automatically) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=935
Diffstat (limited to 'xlators/protocol')
-rw-r--r--xlators/protocol/server/src/server-resolve.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/protocol/server/src/server-resolve.c b/xlators/protocol/server/src/server-resolve.c
index 8a390689f10..65d7badfae8 100644
--- a/xlators/protocol/server/src/server-resolve.c
+++ b/xlators/protocol/server/src/server-resolve.c
@@ -108,7 +108,7 @@ resolve_loc_touchup (call_frame_t *frame)
loc = state->loc_now;
if (!loc->path) {
- if (loc->parent) {
+ if (loc->parent && resolve->bname) {
ret = inode_path (loc->parent, resolve->bname, &path);
} else if (loc->inode) {
ret = inode_path (loc->inode, NULL, &path);