blob: ae333ac22091a1ebc91e17fecec1b25f00f0753c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
Author: Iustin Pop <iusty@k1024.org>
Description: Fix the inet_addr result check with correct type casting
--- a/cbtcommon/tcpsocket.c
+++ b/cbtcommon/tcpsocket.c
@@ -198,7 +198,7 @@
memcpy(dest, &ip.s_addr, sizeof(ip.s_addr));
}
#else
- if ( (*dest = inet_addr(addr_str)) != -1)
+ if ( (*dest = inet_addr(addr_str)) != (in_addr_t)-1)
{
/* nothing */
}
|