From: Jim Meyering Date: Mon, 26 Apr 1999 02:19:51 +0000 (+0000) Subject: (main): Revert last change. X-Git-Tag: SH-UTILS-1_16h~50 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3baa7fa854482a64019861c9eb8182610edc2c59;p=platform%2Fupstream%2Fcoreutils.git (main): Revert last change. Instead, loop on `optind < argc' to protect use of argv[optind]. --- diff --git a/src/seq.c b/src/seq.c index 27ebc9df0..613627dd0 100644 --- a/src/seq.c +++ b/src/seq.c @@ -143,7 +143,7 @@ main (int argc, char **argv) /* We have to handle negative numbers in the command line but this conflicts with the command line arguments. So explicitly check first whether the next argument looks like a negative number. */ - while (1) + while (optind < argc) { if (argv[optind][0] == '-' && ((optc = argv[optind][1]) == decimal_point[0]