summaryrefslogtreecommitdiffstats
path: root/apropos.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2011-11-28 09:44:05 +0000
committerIngo Schwarze <schwarze@openbsd.org>2011-11-28 09:44:05 +0000
commit0dc7ca4abf72bcae5cbcea1c36e8fe686fbf5b16 (patch)
tree46d100e8643ea51017727f8cbcb27e6bf83a2cf4 /apropos.c
parent591006fe672adf9c166b9440176e03ed1554191e (diff)
downloadmandoc-0dc7ca4abf72bcae5cbcea1c36e8fe686fbf5b16.tar.gz
Tweak whatis(1):
* Bugfix: Use all arguments, not just the last one. * Use 'Nm~' instead of 'Nm,Nd~' to match OpenBSD behaviour. * For the progname, accept '^whatis', not '^whatis$' to ease testing. ok kristaps@
Diffstat (limited to 'apropos.c')
-rw-r--r--apropos.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/apropos.c b/apropos.c
index 95c92d03..0d97c82a 100644
--- a/apropos.c
+++ b/apropos.c
@@ -53,7 +53,7 @@ main(int argc, char *argv[])
else
++progname;
- whatis = 0 == strcmp(progname, "whatis");
+ whatis = 0 == strncmp(progname, "whatis", 6);
memset(&paths, 0, sizeof(struct manpaths));
memset(&opts, 0, sizeof(struct opts));