From c81ba0cd844ef2ade9cb6450e3ba39ac0aff5bab Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Wed, 22 Feb 2017 08:54:41 +0000 Subject: Handle an odd edge case where .It is preceded by .Sm. NULL dereference in man.cgi reported by Gabriel Guzman on misc@. --- mdoc_html.c | 1 + 1 file changed, 1 insertion(+) (limited to 'mdoc_html.c') diff --git a/mdoc_html.c b/mdoc_html.c index 7c67d072..1a9b9d84 100644 --- a/mdoc_html.c +++ b/mdoc_html.c @@ -751,6 +751,7 @@ mdoc_it_pre(MDOC_ARGS) case ROFFT_HEAD: if (h->style != NULL && !bl->norm->Bl.comp && (n->parent->prev == NULL || + n->parent->prev->body == NULL || n->parent->prev->body->child != NULL)) { t = print_otag(h, TAG_DT, "csWl", cattr, bl->norm->Bl.width); -- cgit