summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--usr.bin/ypwhich/ypwhich.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/usr.bin/ypwhich/ypwhich.c b/usr.bin/ypwhich/ypwhich.c
index 9137c99..1c6f36c 100644
--- a/usr.bin/ypwhich/ypwhich.c
+++ b/usr.bin/ypwhich/ypwhich.c
@@ -28,7 +28,6 @@
*/
#include <sys/cdefs.h>
-
__FBSDID("$FreeBSD$");
#include <sys/param.h>
@@ -185,7 +184,7 @@ main(int argc, char *argv[])
case 1:
bzero(&lsin, sizeof lsin);
lsin.sin_family = AF_INET;
- if ((lsin.sin_addr.s_addr = inet_addr(argv[optind])) == -1) {
+ if ((lsin.sin_addr.s_addr = inet_addr(argv[optind])) == INADDR_NONE) {
hent = gethostbyname(argv[optind]);
if (!hent)
errx(ERR_NOSUCHHOST, "host %s unknown", argv[optind]);
OpenPOWER on IntegriCloud