From fc8b3fcbe1ab7fa8a7b15437d49df287856f2e95 Mon Sep 17 00:00:00 2001 From: Vijay Bellur Date: Thu, 26 Aug 2010 13:31:23 +0000 Subject: cluster/afr: Hold ref on the right fd Signed-off-by: Vijay Bellur Signed-off-by: Vijay Bellur BUG: 1365 ([3.1.0qa5-15] Self-heal doesn't happen from 1st subvolume to others) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1365 --- xlators/cluster/afr/src/afr-open.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'xlators') diff --git a/xlators/cluster/afr/src/afr-open.c b/xlators/cluster/afr/src/afr-open.c index c8603be33ac..dc830f7d59d 100644 --- a/xlators/cluster/afr/src/afr-open.c +++ b/xlators/cluster/afr/src/afr-open.c @@ -440,6 +440,7 @@ out: gf_log (this->name, GF_LOG_TRACE, "The up/down flush is over"); + fd_unref (local->fd); local->up_down_flush_cbk (frame, this); return 0; @@ -460,7 +461,7 @@ afr_up_down_flush (call_frame_t *frame, xlator_t *this, fd_t *fd, local->op = GF_FOP_FLUSH; - local->fd = fd_ref (local->fd); + local->fd = fd_ref (fd); local->transaction.fop = afr_up_down_flush_wind; local->transaction.done = afr_up_down_flush_done; -- cgit