diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2010-08-07 17:26:12 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2010-08-07 17:26:12 +0000 |
commit | 783bbf4cfe3e9b732ba2baef0909b7b0cb9cf60c (patch) | |
tree | 35e0b8520696d1e48e2c060077ba9647af7bb648 /usr.bin | |
parent | ab7ac0049e24b654e169567257a97902f903ca5d (diff) |
In -Thtml output, preserve blank lines at the end of .Bd -literal.
Patch from kristaps@, analoguous to mdoc_term.c rev. 1.100.
With permission from deraadt@ to still fix bugs in mandoc.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mandoc/mdoc_html.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.bin/mandoc/mdoc_html.c b/usr.bin/mandoc/mdoc_html.c index 832f74fe9cd..1f7ef4daa49 100644 --- a/usr.bin/mandoc/mdoc_html.c +++ b/usr.bin/mandoc/mdoc_html.c @@ -1,4 +1,4 @@ -/* $Id: mdoc_html.c,v 1.27 2010/07/31 21:43:07 schwarze Exp $ */ +/* $Id: mdoc_html.c,v 1.28 2010/08/07 17:26:11 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv> * @@ -1453,11 +1453,11 @@ mdoc_bd_pre(MDOC_ARGS) print_otag(h, TAG_DIV, 2, tag); for (nn = n->child; nn; nn = nn->next) { - if (nn->prev && nn->prev->line < nn->line) { - print_text(h, "\n"); - h->flags |= HTML_NOSPACE; - } print_mdoc_node(m, nn, h); + if (nn->next && nn->next->line == nn->line) + continue; + print_text(h, "\n"); + h->flags |= HTML_NOSPACE; } return(0); |