From 4ce81d4dccbf74bc20e049b08cf4fc712168fdf4 Mon Sep 17 00:00:00 2001 From: Qualys Security Advisory Date: Thu, 1 Jan 1970 00:00:00 +0000 Subject: [PATCH 14/65] vmstat: getopt*() returns -1 when done, not EOF. Luckily, EOF is usually -1, but this is not guaranteed by the standard. --- vmstat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vmstat.c b/vmstat.c index f2aa2f4..6eca2c4 100644 --- a/vmstat.c +++ b/vmstat.c @@ -878,7 +878,7 @@ int main(int argc, char *argv[]) while ((c = getopt_long(argc, argv, "afmnsdDp:S:wthV", longopts, - NULL)) != EOF) + NULL)) != -1) switch (c) { case 'V': printf(PROCPS_NG_VERSION); -- 2.6.4.windows.1