summaryrefslogtreecommitdiffstats
path: root/mansearch.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2014-01-19 23:09:30 +0000
committerIngo Schwarze <schwarze@openbsd.org>2014-01-19 23:09:30 +0000
commit2aad24e2bd886f7b1bf4d4844f1acd7283ab2aba (patch)
treecf5fd0a76dd59f44b014fffbd188f9423e3ea149 /mansearch.c
parent47affe011d1514ddca9022d23c41966cfbfc705e (diff)
downloadmandoc-2aad24e2bd886f7b1bf4d4844f1acd7283ab2aba.tar.gz
Always compare arch case-insensitively.
Diffstat (limited to 'mansearch.c')
-rw-r--r--mansearch.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mansearch.c b/mansearch.c
index 86f52e77..fe5def6a 100644
--- a/mansearch.c
+++ b/mansearch.c
@@ -608,6 +608,8 @@ exprterm(const struct mansearch *search, char *buf, int cs)
e->bits = search->deftype;
if ('~' == *v++) {
+ if (NULL != strstr(buf, "arch"))
+ cs = 0;
if (0 != (irc = regcomp(&e->regexp, v,
REG_EXTENDED | REG_NOSUB | (cs ? 0 : REG_ICASE)))) {
regerror(irc, &e->regexp, errbuf, sizeof(errbuf));