summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2016-07-10 14:05:13 +0000
committerIngo Schwarze <schwarze@openbsd.org>2016-07-10 14:05:13 +0000
commit3a31e61ef7834baad64300f86374bf54b87bb250 (patch)
tree6a0c0a90add950110f373361cc559b56ab7134d0
parent9efbcc1d41b6068c746255b6a5006d3d96fb7834 (diff)
downloadmandoc-3a31e61ef7834baad64300f86374bf54b87bb250.tar.gz
On OpenBSD, more(1) is actually less(1) with a small number of
compatibility features - so we can safely use more -T on OpenBSD. But don't do that in the portable version: more -T is unlikely to work elsewhere. Issue reported by Svyatoslav Mishyn <juef at openmailbox dot org>.
-rw-r--r--main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.c b/main.c
index 461c91e4..71648b0e 100644
--- a/main.c
+++ b/main.c
@@ -1055,11 +1055,11 @@ spawn_pager(struct tag_files *tag_files)
break;
}
- /* For more(1) and less(1), use the tag file. */
+ /* For less(1), use the tag file. */
if ((cmdlen = strlen(argv[0])) >= 4) {
cp = argv[0] + cmdlen - 4;
- if (strcmp(cp, "less") == 0 || strcmp(cp, "more") == 0) {
+ if (strcmp(cp, "less") == 0) {
argv[argc++] = mandoc_strdup("-T");
argv[argc++] = tag_files->tfn;
}