coverity: improper use of negative value

This commit is contained in:
Laxmikant Rashinkar
2014-07-26 13:33:23 -07:00
parent fde7be5151
commit 27055d5762
13 changed files with 82 additions and 17 deletions
+5
View File
@@ -212,10 +212,15 @@ lib_mod_connect(struct mod *mod)
if (use_uds)
{
mod->sck = g_tcp_local_socket();
if (mod->sck < 0)
return 1;
}
else
{
mod->sck = g_tcp_socket();
if (mod->sck < 0)
return 1;
g_tcp_set_non_blocking(mod->sck);
g_tcp_set_no_delay(mod->sck);
}