From b9cdce5e2c6ac5727fb1b310510e938e6325e729 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Fri, 21 Aug 2026 10:37:55 -0700 Subject: [PATCH] scripts: remove EOF == -1 assumption MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * scripts/xsparse.c (main): Don’t assume EOF == -1. --- scripts/xsparse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/xsparse.c b/scripts/xsparse.c index 404996b2..336a16f9 100644 --- a/scripts/xsparse.c +++ b/scripts/xsparse.c @@ -352,7 +352,7 @@ main (int argc, char **argv) char *xheader_file = NULL; progname = argv[0]; - while ((c = getopt (argc, argv, "hnvx:")) != EOF) + while (0 <= (c = getopt (argc, argv, "hnvx:"))) { switch (c) {