diff options
author | 2011-07-31 14:11:48 +0000 | |
---|---|---|
committer | 2011-07-31 14:11:48 +0000 | |
commit | 82475fc355de9a5b686ab143be7a5855443723d9 (patch) | |
tree | cee1c747fbeb31c6d0976ccb2527d97d1829192e | |
parent | missing .Nm macro; ok jmc@ (diff) | |
download | wireguard-openbsd-82475fc355de9a5b686ab143be7a5855443723d9.tar.xz wireguard-openbsd-82475fc355de9a5b686ab143be7a5855443723d9.zip |
Workaround to prevent misrendering of \*(-- as "O-" in pod2man(1)-
generated manuals; this fixes more than 500 manuals in base alone.
As a real fix, .tr will be supported after unlock.
OK kristaps@ to put in the workaround for now
-rw-r--r-- | usr.bin/mandoc/roff.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/usr.bin/mandoc/roff.c b/usr.bin/mandoc/roff.c index b6e50bad52c..5cc504e3eee 100644 --- a/usr.bin/mandoc/roff.c +++ b/usr.bin/mandoc/roff.c @@ -1,4 +1,4 @@ -/* $Id: roff.c,v 1.39 2011/07/07 20:07:38 schwarze Exp $ */ +/* $Id: roff.c,v 1.40 2011/07/31 14:11:48 schwarze Exp $ */ /* * Copyright (c) 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010, 2011 Ingo Schwarze <schwarze@openbsd.org> @@ -1344,6 +1344,12 @@ roff_setstr(struct roff *r, const char *name, const char *string, char *c; size_t oldch, newch; + /* XXX workaround for the Perl preamble until we get .tr */ + if ( ! strcmp(name, "--")) { + string = "--"; + multiline = 0; + } + /* Search for an existing string with the same name. */ n = r->first_string; while (n && strcmp(name, n->name)) |