summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorHarpreet Lalwani <hlalwani@redhat.com>2018-09-11 23:00:14 +0530
committerAtin Mukherjee <amukherj@redhat.com>2018-09-17 12:08:53 +0000
commitf7f281900b3c87e3626d79bd9599c905faaf11ed (patch)
treeda40bbce02c789769ba5a68381f5b5a2602c26d7 /xlators
parentbdfe87d56b21766cf7fe9f73890d1d3336158982 (diff)
glusterd: NULL pointer dereferencing clang Fix
Added ternary operator to avoid NULL pointer dereferencing Updates: bz#1622665 Change-Id: I855f6caf720b28af1564898d75c6c965bcc58c5c Signed-off-by: Harpreet Lalwani <hlalwani@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-geo-rep.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-geo-rep.c b/xlators/mgmt/glusterd/src/glusterd-geo-rep.c
index 075fdf74369..b550d373ed2 100644
--- a/xlators/mgmt/glusterd/src/glusterd-geo-rep.c
+++ b/xlators/mgmt/glusterd/src/glusterd-geo-rep.c
@@ -1342,7 +1342,7 @@ out:
if (slave_host)
GF_FREE(slave_host);
- gf_msg_debug(this->name, 0, "Returning %d.", ret);
+ gf_msg_debug(this ? this->name : "glusterd", 0, "Returning %d.", ret);
return ret;
}