summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorAnuradha <atalur@redhat.com>2015-05-12 12:53:30 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2015-05-13 04:54:30 -0700
commit2b92a5c5efc29b05de88631bc5423ae3eec43812 (patch)
tree337dea35bc8732f54ba7b472fb23ee0da83e3d68 /xlators
parentef37da74d4a8595cf53cf6dfe680fe080b7c8704 (diff)
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 <atalur@redhat.com> Reviewed-on: http://review.gluster.org/10755 Reviewed-by: Ravishankar N <ravishankar@redhat.com> Reviewed-by: Prashanth Pai <ppai@redhat.com> Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Susant Palai <spalai@redhat.com> Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/cluster/afr/src/afr-common.c2
1 files changed, 1 insertions, 1 deletions
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);