diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-04-04 13:53:00 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-04-04 13:53:00 +0000 |
commit | d38c7a9a5f3ac742656dcf66f5f6205b39714767 (patch) | |
tree | 2b4f773a4560f192ee991fcf8076b0b095a29a98 /usr.bin/mandoc | |
parent | 2b96c2eb91adbafa5ee2b3906bdefb58c465f5d9 (diff) |
Don't allow breaking the output line after hyphens following escape
sequences. Improves tic(1), sxpm(1), and a few Perl manuals.
Quirk found by naddy@ in milter-greylist(8).
Diffstat (limited to 'usr.bin/mandoc')
-rw-r--r-- | usr.bin/mandoc/roff.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.bin/mandoc/roff.c b/usr.bin/mandoc/roff.c index 3835f1adbfa..32b7f1d30c4 100644 --- a/usr.bin/mandoc/roff.c +++ b/usr.bin/mandoc/roff.c @@ -1,4 +1,4 @@ -/* $OpenBSD: roff.c,v 1.135 2015/02/21 14:46:33 schwarze Exp $ */ +/* $OpenBSD: roff.c,v 1.136 2015/04/04 13:52:59 schwarze Exp $ */ /* * Copyright (c) 2010, 2011, 2012, 2014 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010-2015 Ingo Schwarze <schwarze@openbsd.org> @@ -1126,6 +1126,8 @@ roff_parsetext(struct buf *buf, int pos, int *offs) esc = mandoc_escape((const char **)&p, NULL, NULL); if (esc == ESCAPE_ERROR) break; + while (*p == '-') + p++; continue; } else if (p == start) { p++; |