From: Jim Meyering Date: Sun, 4 Aug 1996 14:15:25 +0000 (+0000) Subject: (main): Allow `+' in options like -+8 and -+13. X-Git-Tag: TEXTUTILS-1_19b~85 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7532e5794186b48dfb6532191c40c8e3a80ea702;p=thirdparty%2Fcoreutils.git (main): Allow `+' in options like -+8 and -+13. --- diff --git a/src/nice.c b/src/nice.c index e05cf79383..c9e2713139 100644 --- a/src/nice.c +++ b/src/nice.c @@ -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);