diff options
author | Leah Neukirchen <leah@vuxu.org> | 2020-04-13 21:05:36 +0200 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2020-04-13 21:05:55 +0200 |
commit | d00744ca0b07c19527f593bd2504aa6dd17e5988 (patch) | |
tree | 73e71a3fc808fd0b61fa27bf798851388039a6ee | |
parent | 6769ad22d2d6c1fd2c996eb98f788148fdf7fbc8 (diff) | |
download | outils-d00744ca0b07c19527f593bd2504aa6dd17e5988.tar.gz outils-d00744ca0b07c19527f593bd2504aa6dd17e5988.tar.xz outils-d00744ca0b07c19527f593bd2504aa6dd17e5988.zip |
jot: default prec to 0 with no arguments
Fixes #6.
-rw-r--r-- | src/usr.bin/jot/jot.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/usr.bin/jot/jot.c b/src/usr.bin/jot/jot.c index c84a8cb..fa74270 100644 --- a/src/usr.bin/jot/jot.c +++ b/src/usr.bin/jot/jot.c @@ -164,6 +164,8 @@ main(int argc, char *argv[]) prec = 0; } case 0: + if (prec == -1) + prec = 0; break; default: errx(1, "Too many arguments. What do you mean by %s?", |