From 28e5db027122e5f7684d09362a425f63bbc5c4a2 Mon Sep 17 00:00:00 2001 From: ache Date: Mon, 17 Jun 1996 18:35:16 +0000 Subject: Don't try convert "-" to numeric form for -n option --- usr.bin/w/w.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'usr.bin/w/w.c') diff --git a/usr.bin/w/w.c b/usr.bin/w/w.c index 06c9d72..96b0a2b 100644 --- a/usr.bin/w/w.c +++ b/usr.bin/w/w.c @@ -323,7 +323,7 @@ main(argc, argv) } p = hp->h_name; } - if (nflag && inet_addr(p) == INADDR_NONE) { + if (nflag && strcmp(p, "-") && inet_addr(p) == INADDR_NONE) { hp = gethostbyname(p); if (hp != NULL) { -- cgit v1.1