summaryrefslogtreecommitdiffstats
path: root/mdoc_man.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2013-09-15 18:48:31 +0000
committerIngo Schwarze <schwarze@openbsd.org>2013-09-15 18:48:31 +0000
commit7223d0082a81c4411fa68997f0462c2c3b79c1e7 (patch)
treee8868367646e52c599411fcbdd25f6a2afb41753 /mdoc_man.c
parent8e08c89dd46d82aaf2e087ce16eca0e73c414481 (diff)
downloadmandoc-7223d0082a81c4411fa68997f0462c2c3b79c1e7.tar.gz
Use normal line macro recognition, do not attempt to roll your own.
This fixes horizontal spacing when an Ns macro follows a block-closing macro and the corresponding block-opening macro is not on the same line.
Diffstat (limited to 'mdoc_man.c')
-rw-r--r--mdoc_man.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/mdoc_man.c b/mdoc_man.c
index c1c748ec..216a4d3c 100644
--- a/mdoc_man.c
+++ b/mdoc_man.c
@@ -553,7 +553,7 @@ man_mdoc(void *arg, const struct mdoc *mdoc)
static void
print_node(DECL_ARGS)
{
- const struct mdoc_node *prev, *sub;
+ const struct mdoc_node *sub;
const struct manact *act;
int cond, do_sub;
@@ -561,8 +561,7 @@ print_node(DECL_ARGS)
* Break the line if we were parsed subsequent the current node.
* This makes the page structure be more consistent.
*/
- prev = n->prev ? n->prev : n->parent;
- if (MMAN_spc & outflags && prev && prev->line < n->line)
+ if (MMAN_spc & outflags && MDOC_LINE & n->flags)
outflags |= MMAN_nl;
act = NULL;