diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-05-01 15:27:18 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-05-01 15:27:18 +0000 |
commit | 80871623029d7eaceb46f14635ca9e50cf8398ad (patch) | |
tree | a42c9d2b067879754e988f2b865798973af7009d | |
parent | f3bd8ae2f67589b1d9eeaf21402768d1203c1ae8 (diff) |
Minor bug fix: When .Pp rewinds .Nm, rewind the whole block,
not just the body. In some unusual edge cases, this caused
the .Pp to become a sibling of the .Nm body inside the .Nm block.
-rw-r--r-- | usr.bin/mandoc/mdoc_macro.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/mandoc/mdoc_macro.c b/usr.bin/mandoc/mdoc_macro.c index 1e37532b2c6..fb33821ae94 100644 --- a/usr.bin/mandoc/mdoc_macro.c +++ b/usr.bin/mandoc/mdoc_macro.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mdoc_macro.c,v 1.153 2015/04/29 21:57:50 schwarze Exp $ */ +/* $OpenBSD: mdoc_macro.c,v 1.154 2015/05/01 15:27:17 schwarze Exp $ */ /* * Copyright (c) 2008-2012 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010, 2012-2015 Ingo Schwarze <schwarze@openbsd.org> @@ -1397,7 +1397,7 @@ in_line_eoln(MACRO_PROT_ARGS) if (mdoc->next == ROFF_NEXT_SIBLING) n = n->parent; if (n->tok == MDOC_Nm) - rew_last(mdoc, mdoc->last->parent); + rew_last(mdoc, n->parent); } if (buf[*pos] == '\0' && |