summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZhou Zhengping <johnzzpcrystal@gmail.com>2016-04-10 23:56:17 +0800
committerRaghavendra G <rgowdapp@redhat.com>2016-05-27 02:07:12 -0700
commit1b44116337b9ef59c2286b88e0b90d596caab270 (patch)
treeaed97f560557b4b99a31a029a002aae6ead20978
parentc88c20f7932cd5b49db5a1ae963c683d4b465b4b (diff)
rpc: check the right variable after gf_strdup
> Reviewed-on: http://review.gluster.org/13934 > Smoke: Gluster Build System <jenkins@build.gluster.com> > Tested-by: Jeff Darcy <jdarcy@redhat.com> > Reviewed-by: Anoop C S <anoopcs@redhat.com> > NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> > Reviewed-by: Vijay Bellur <vbellur@redhat.com> > CentOS-regression: Gluster Build System <jenkins@build.gluster.com> (cherry picked from commit 1c9c776352c60deeda51be66fda6d44bf06d3796) Change-Id: If4628bd37f2c85a070f6c3b3e0583d939100d7ec BUG: 1332404 Signed-off-by: Zhou Zhengping <johnzzpcrystal@gmail.com> Reviewed-on: http://review.gluster.org/14494 Smoke: Gluster Build System <jenkins@build.gluster.com> Tested-by: Anoop C S <anoopcs@redhat.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
-rw-r--r--rpc/rpc-lib/src/rpc-transport.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rpc/rpc-lib/src/rpc-transport.c b/rpc/rpc-lib/src/rpc-transport.c
index 0904dbee716..1cd16831e22 100644
--- a/rpc/rpc-lib/src/rpc-transport.c
+++ b/rpc/rpc-lib/src/rpc-transport.c
@@ -674,7 +674,7 @@ rpc_transport_inet_options_build (dict_t **options, const char *hostname,
goto out;
host = gf_strdup ((char*)hostname);
- if (!hostname) {
+ if (!host) {
ret = -1;
goto out;
}