diff options
author | Gustavo Sverzut Barbieri <barbieri@profusion.mobi> | 2016-12-12 13:02:55 -0200 |
---|---|---|
committer | Gustavo Sverzut Barbieri <barbieri@profusion.mobi> | 2016-12-12 13:02:55 -0200 |
commit | 4f44287a596e0ae25009213bad40b4730ce5b71d (patch) | |
tree | 97a62eec443759ff7c28eb1c3acc559f8d5bb2c9 | |
parent | c4ab9882e12c90c45c514aa1057448d3ed39bf75 (diff) | |
download | efl-4f44287a596e0ae25009213bad40b4730ce5b71d.tar.gz |
efl_net_ip_address: make coverity happy.
host and port were already checked, but let's quiet CID 1366921
-rw-r--r-- | src/lib/ecore_con/efl_net_ip_address.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/ecore_con/efl_net_ip_address.c b/src/lib/ecore_con/efl_net_ip_address.c index 0109748cb8..e76a3834aa 100644 --- a/src/lib/ecore_con/efl_net_ip_address.c +++ b/src/lib/ecore_con/efl_net_ip_address.c @@ -512,6 +512,7 @@ _efl_net_ip_address_resolve(Eo *cls EINA_UNUSED, void *pd EINA_UNUSED, const cha Efl_Net_Ip_Address_Resolve_Context *ctx; struct addrinfo hints = { }; const char *host = NULL, *port = NULL; + Eina_Bool r; char *str; EINA_SAFETY_ON_NULL_RETURN_VAL(address, NULL); @@ -526,8 +527,8 @@ _efl_net_ip_address_resolve(Eo *cls EINA_UNUSED, void *pd EINA_UNUSED, const cha str = strdup(address); EINA_SAFETY_ON_NULL_RETURN_VAL(str, NULL); - efl_net_ip_port_split(str, &host, &port); - if ((!host) || (host[0] == '\0')) + r = efl_net_ip_port_split(str, &host, &port); + if ((!r) || (!host) || (host[0] == '\0')) { host = address; port = "0"; |