From 141381e1cbdbd8001c13e9e8c0adbfc81d1b3cd0 Mon Sep 17 00:00:00 2001 From: imp Date: Sat, 29 Mar 1997 04:34:07 +0000 Subject: compare return value from getopt against -1 rather than EOF, per the final posix standard on the topic. --- usr.bin/netstat/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'usr.bin/netstat/main.c') diff --git a/usr.bin/netstat/main.c b/usr.bin/netstat/main.c index 4bf8719..56b9080 100644 --- a/usr.bin/netstat/main.c +++ b/usr.bin/netstat/main.c @@ -250,7 +250,7 @@ main(argc, argv) prog = argv[0]; af = AF_UNSPEC; - while ((ch = getopt(argc, argv, "Aabdf:ghI:iM:mN:np:rstuw:")) != EOF) + while ((ch = getopt(argc, argv, "Aabdf:ghI:iM:mN:np:rstuw:")) != -1) switch(ch) { case 'A': Aflag = 1; -- cgit v1.1