summaryrefslogtreecommitdiffstats
path: root/validate.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-01-16 12:23:25 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-01-16 12:23:25 +0000
commitd460b17b87e787b48938270b20eb4088e5c343ab (patch)
tree327c0f9b78231c4427c0222aba82f007a6e28ba7 /validate.c
parentc3f113eda71022f3ea3245ce53f3878057139149 (diff)
downloadmandoc-d460b17b87e787b48938270b20eb4088e5c343ab.tar.gz
Clean-ups & documentation.
Diffstat (limited to 'validate.c')
-rw-r--r--validate.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/validate.c b/validate.c
index dbe41e4f..9f9d5cde 100644
--- a/validate.c
+++ b/validate.c
@@ -306,7 +306,8 @@ pre_display(struct mdoc *mdoc, struct mdoc_node *node)
if (MDOC_BLOCK != node->type)
return(1);
- for (n = mdoc->last; n; n = n->parent)
+ assert(mdoc->last);
+ for (n = mdoc->last->parent; n; n = n->parent)
if (MDOC_BLOCK == n->type)
if (MDOC_Bd == n->tok)
break;