inet_pton returns either 1, 0, or -1. [ISC-Bugs #18511]
some problems to some failover installations. We will revisit this
in future releases.
+- The !inet_pton() call in res_mkupdrec was adjusted to '<= 0' as
+ inet_pton returns either 1, 0, or -1.
+
Changes since 4.1.0a1
- Corrected list of failover state values in dhcpd man page.
*/
#if !defined(lint) && !defined(SABER)
-static const char rcsid[] = "$Id: res_mkupdate.c,v 1.12 2008/02/28 21:21:56 dhankins Exp $";
+static const char rcsid[] = "$Id: res_mkupdate.c,v 1.13 2008/11/03 21:39:31 dhankins Exp $";
#endif /* not lint */
#include <sys/types.h>
case T_AAAA:
if (!getword_str(buf2, sizeof buf2, &startp, endp))
return (-1);
- if (!inet_pton(AF_INET6, buf2, &in6a))
+ if (inet_pton(AF_INET6, buf2, &in6a) <= 0)
return (-1);
n = sizeof(struct in6_addr);
memcpy(cp, &in6a, n);