summaryrefslogtreecommitdiffstats
path: root/mdoc_term.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2014-07-30 17:06:26 +0000
committerIngo Schwarze <schwarze@openbsd.org>2014-07-30 17:06:26 +0000
commit8cad25c2bd23b7a8d1c081a886ca26c2ff2d1e10 (patch)
tree69a65683cbfaf670639bea17ed5d29aebd6121e5 /mdoc_term.c
parent16567ee6b0b51e693f21d13f133f9fa14e59d992 (diff)
downloadmandoc-8cad25c2bd23b7a8d1c081a886ca26c2ff2d1e10.tar.gz
Get rid of the useless FATAL error "child violates parent syntax".
When finding items outside lists, simply skip them and throw an ERROR. Handle subsections before the first section instead of bailing out.
Diffstat (limited to 'mdoc_term.c')
-rw-r--r--mdoc_term.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/mdoc_term.c b/mdoc_term.c
index 63829263..ea34908c 100644
--- a/mdoc_term.c
+++ b/mdoc_term.c
@@ -1770,6 +1770,9 @@ termp_ss_pre(DECL_ARGS)
term_fontpush(p, TERMFONT_BOLD);
p->offset = term_len(p, (p->defindent+1)/2);
break;
+ case MDOC_BODY:
+ p->offset = term_len(p, p->defindent);
+ break;
default:
break;
}
@@ -1781,7 +1784,7 @@ static void
termp_ss_post(DECL_ARGS)
{
- if (MDOC_HEAD == n->type)
+ if (n->type == MDOC_HEAD || n->type == MDOC_BODY)
term_newln(p);
}