summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorJeff Darcy <jdarcy@redhat.com>2011-12-13 17:13:59 -0500
committerVijay Bellur <vijay@gluster.com>2011-12-19 21:40:32 -0800
commit2a3e74e7a68aac1ad6d89122bbc4d64cd304986b (patch)
tree8a354f8c43c269d5bc4b09ca296dead387ffdce2 /xlators
parent255fed3b0d5b9d210d1da47dbd647dd6497cd550 (diff)
Fix local==NULL crash in wb_sync_cbk during disconnect.
Change-Id: I26dc48a85756e189b1ef5cfef1658f9c2aed2157 BUG: 767359 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.com/784 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/protocol/client/src/client3_1-fops.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/xlators/protocol/client/src/client3_1-fops.c b/xlators/protocol/client/src/client3_1-fops.c
index 98d19c701e8..9b0fd63cc68 100644
--- a/xlators/protocol/client/src/client3_1-fops.c
+++ b/xlators/protocol/client/src/client3_1-fops.c
@@ -3623,12 +3623,19 @@ client3_1_writev (call_frame_t *frame, xlator_t *this, void *data)
client3_1_writev_cbk, args->vector,
args->count, args->iobref,
(xdrproc_t)xdr_gfs3_write_req);
- if (ret)
- goto unwind;
+ if (ret) {
+ /*
+ * If the lower layers fail to submit a request, they'll also
+ * do the unwind for us (see rpc_clnt_submit), so don't unwind
+ * here in such cases.
+ */
+ gf_log (this->name, GF_LOG_WARNING,
+ "failed to send the fop: %s", strerror (op_errno));
+ }
return 0;
+
unwind:
- gf_log (this->name, GF_LOG_WARNING, "failed to send the fop: %s", strerror (op_errno));
STACK_UNWIND_STRICT (writev, frame, -1, op_errno, NULL, NULL);
return 0;
}