summaryrefslogtreecommitdiffstats
path: root/xlators/protocol/client
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendrabhat@gluster.com>2012-05-22 17:21:20 +0530
committerAnand Avati <avati@redhat.com>2012-05-22 12:16:48 -0700
commit2eb4a5b86596fbcbb1c0baa9f1b7de0843896dd9 (patch)
tree9b01e035b50d5bd2cf98c6f5a4b0ccd4cc000f70 /xlators/protocol/client
parent0a1ca704cc5668a8d227b07565ea17a462666efb (diff)
protocol/client: do not print the null gfid when symlink fails
Change-Id: I1a2748768bc30a00c4f7b2e2fda1d282bc581658 BUG: 823880 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/3411 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
Diffstat (limited to 'xlators/protocol/client')
-rw-r--r--xlators/protocol/client/src/client3_1-fops.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/xlators/protocol/client/src/client3_1-fops.c b/xlators/protocol/client/src/client3_1-fops.c
index 07d55c8956b..061bfcd7e3f 100644
--- a/xlators/protocol/client/src/client3_1-fops.c
+++ b/xlators/protocol/client/src/client3_1-fops.c
@@ -179,12 +179,14 @@ client3_1_symlink_cbk (struct rpc_req *req, struct iovec *iov, int count,
out:
if (rsp.op_ret == -1) {
+ /* no need to print the gfid, because it will be null, since
+ * symlink operation failed.
+ */
gf_log (this->name, GF_LOG_WARNING,
- "remote operation failed: %s. Path: %s (%s)",
+ "remote operation failed: %s. Path: (%s to %s)",
strerror (gf_error_to_errno (rsp.op_errno)),
(local) ? local->loc.path : "--",
- (local && local->loc.inode) ?
- uuid_utoa (local->loc.inode->gfid) : "--");
+ (local) ? local->loc2.path: "--");
}
CLIENT_STACK_UNWIND (symlink, frame, rsp.op_ret,
@@ -3436,6 +3438,7 @@ client3_1_symlink (call_frame_t *frame, xlator_t *this,
req.linkname = (char *)args->linkname;
req.bname = (char *)args->loc->name;
req.umask = args->umask;
+ local->loc2.path = gf_strdup (req.linkname);
conf = this->private;