]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(main): Handle the case in which seq is given no args.
authorJim Meyering <jim@meyering.net>
Mon, 26 Apr 1999 00:39:47 +0000 (00:39 +0000)
committerJim Meyering <jim@meyering.net>
Mon, 26 Apr 1999 00:39:47 +0000 (00:39 +0000)
src/seq.c

index 27ebc9df0e5699b62542fccea4bb80a36ae9503b..af2be47c6eaafd302884361440c7881ecac06ba7 100644 (file)
--- a/src/seq.c
+++ b/src/seq.c
@@ -140,6 +140,12 @@ main (int argc, char **argv)
   }
 #endif
 
+  if (argc == 1)
+    {
+      error (0, 0, _("too few arguments"));
+      usage (1);
+    }
+
   /* 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.  */