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/vmstat/vmstat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'usr.bin/vmstat') diff --git a/usr.bin/vmstat/vmstat.c b/usr.bin/vmstat/vmstat.c index 6f65a30..fe363a2 100644 --- a/usr.bin/vmstat/vmstat.c +++ b/usr.bin/vmstat/vmstat.c @@ -184,7 +184,7 @@ main(argc, argv) memf = nlistf = NULL; interval = reps = todo = 0; - while ((c = getopt(argc, argv, "c:fiM:mN:stw:")) != EOF) { + while ((c = getopt(argc, argv, "c:fiM:mN:stw:")) != -1) { switch (c) { case 'c': reps = atoi(optarg); -- cgit v1.1