From 3340a896a15fdfbfff2777f3f53a472eb62ae2e9 Mon Sep 17 00:00:00 2001 From: "Christopher R. Hertel" Date: Thu, 23 Jan 2014 13:43:14 -0600 Subject: cluster/stripe: Remove redundant code blocks This appears to have been a cut&paste error. The same set of 12 lines was repeated three times, causing a pointer to allocated memory to be overwritten twice resulting in a memory leak. This patch removes the redundant code. BUG: 789278 CID: 1128915 Change-Id: I3e4a3703b389c00e2a4e99e0a7368c5a3dda74d0 Signed-off-by: Christopher R. Hertel Reviewed-on: http://review.gluster.org/6769 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/cluster/stripe/src/stripe.c | 24 ------------------------ 1 file changed, 24 deletions(-) (limited to 'xlators/cluster/stripe/src') diff --git a/xlators/cluster/stripe/src/stripe.c b/xlators/cluster/stripe/src/stripe.c index c98126225..c736e83ed 100644 --- a/xlators/cluster/stripe/src/stripe.c +++ b/xlators/cluster/stripe/src/stripe.c @@ -4206,30 +4206,6 @@ stripe_zerofill(call_frame_t *frame, xlator_t *this, fd_t *fd, off_t offset, remaining_size = len; - local = mem_get0 (this->local_pool); - if (!local) { - op_errno = ENOMEM; - goto err; - } - fctx = (stripe_fd_ctx_t *)(long)tmp_fctx; - stripe_size = fctx->stripe_size; - - STRIPE_VALIDATE_FCTX (fctx, err); - - remaining_size = len; - - local = mem_get0 (this->local_pool); - if (!local) { - op_errno = ENOMEM; - goto err; - } - fctx = (stripe_fd_ctx_t *)(long)tmp_fctx; - stripe_size = fctx->stripe_size; - - STRIPE_VALIDATE_FCTX (fctx, err); - - remaining_size = len; - local = mem_get0 (this->local_pool); if (!local) { op_errno = ENOMEM; -- cgit