From 74b165a23fdb4791d2dcd83194ef8765bb43716e Mon Sep 17 00:00:00 2001 From: Vijay Bellur Date: Thu, 15 Apr 2010 12:30:37 +0000 Subject: cluster/afr: Check for call_count in ENTRY_RENAME_TRANSACTION Signed-off-by: Vijay Bellur Signed-off-by: Anand V. Avati BUG: 824 (Crash in afr rename transaction) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=824 --- xlators/cluster/afr/src/afr-transaction.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xlators/cluster/afr/src/afr-transaction.c b/xlators/cluster/afr/src/afr-transaction.c index 06e8931f2da..2d689e389bc 100644 --- a/xlators/cluster/afr/src/afr-transaction.c +++ b/xlators/cluster/afr/src/afr-transaction.c @@ -613,7 +613,8 @@ afr_unlock (call_frame_t *frame, xlator_t *this) call_count--; } - if (local->transaction.locked_nodes[i] & LOCKED_YES) { + if (call_count && + local->transaction.locked_nodes[i] & LOCKED_YES) { STACK_WIND (frame, afr_unlock_common_cbk, priv->children[i], priv->children[i]->fops->entrylk, -- cgit