]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(main): Allow `+' in options like -+8 and -+13.
authorJim Meyering <jim@meyering.net>
Sun, 4 Aug 1996 14:15:25 +0000 (14:15 +0000)
committerJim Meyering <jim@meyering.net>
Sun, 4 Aug 1996 14:15:25 +0000 (14:15 +0000)
src/nice.c

index e05cf7938357867a93a9fd32a9a976e79fe04570..c9e27131398fb1cc386436571448a69963175567 100644 (file)
@@ -84,8 +84,11 @@ main (int argc, char **argv)
          adjustment_given = 1;
          ++optind;
        }
-      else if (s[0] == '-' && ISDIGIT (s[1]))
+      else if (s[0] == '-' && (ISDIGIT (s[1])
+                              || (s[1] == '+' && ISDIGIT (s[2]))))
        {
+         if (s[1] == '+')
+           ++s;
          if (!isinteger (&s[1]))
            error (1, 0, _("invalid option `%s'"), s);