From 2b92a5c5efc29b05de88631bc5423ae3eec43812 Mon Sep 17 00:00:00 2001 From: Anuradha Date: Tue, 12 May 2015 12:53:30 +0530 Subject: cluster/afr : Do not copy dict when it is NULL In afr_lookup_xattr_req_prepare(), dict_copy was done even though source dict was NULL. Change-Id: I85a5d2823ba021e7f78c1ce13402a0f16b08cb51 BUG: 1220332 Signed-off-by: Anuradha Reviewed-on: http://review.gluster.org/10755 Reviewed-by: Ravishankar N Reviewed-by: Prashanth Pai Reviewed-by: Krutika Dhananjay Tested-by: Gluster Build System Reviewed-by: Susant Palai Reviewed-by: Pranith Kumar Karampuri --- xlators/cluster/afr/src/afr-common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xlators/cluster/afr') diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c index 46f726da734..690c7c8c15d 100644 --- a/xlators/cluster/afr/src/afr-common.c +++ b/xlators/cluster/afr/src/afr-common.c @@ -951,7 +951,7 @@ afr_lookup_xattr_req_prepare (afr_local_t *local, xlator_t *this, if (!local->xattr_req) goto out; - if (xattr_req != local->xattr_req) + if (xattr_req && (xattr_req != local->xattr_req)) dict_copy (xattr_req, local->xattr_req); ret = afr_xattr_req_prepare (this, local->xattr_req); -- cgit