=================================================================== RCS file: /cvs/mandoc/mdoc_term.c,v retrieving revision 1.308 retrieving revision 1.311 diff -u -p -r1.308 -r1.311 --- mandoc/mdoc_term.c 2015/02/05 01:46:56 1.308 +++ mandoc/mdoc_term.c 2015/02/17 20:37:17 1.311 @@ -1,4 +1,4 @@ -/* $Id: mdoc_term.c,v 1.308 2015/02/05 01:46:56 schwarze Exp $ */ +/* $Id: mdoc_term.c,v 1.311 2015/02/17 20:37:17 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2010, 2012-2015 Ingo Schwarze @@ -309,6 +309,7 @@ print_mdoc_node(DECL_ARGS) chld = 1; offset = p->offset; rmargin = p->rmargin; + n->flags &= ~MDOC_ENDED; n->prev_font = p->fonti; memset(&npair, 0, sizeof(struct termpair)); @@ -361,7 +362,7 @@ print_mdoc_node(DECL_ARGS) print_mdoc_nodelist(p, &npair, meta, n->child); term_fontpopq(p, - (ENDBODY_NOT == n->end ? n : n->pending)->prev_font); + (ENDBODY_NOT == n->end ? n : n->body)->prev_font); switch (n->type) { case MDOC_TEXT: @@ -381,7 +382,7 @@ print_mdoc_node(DECL_ARGS) * that it must not call the post handler again. */ if (ENDBODY_NOT != n->end) - n->pending->flags |= MDOC_ENDED; + n->body->flags |= MDOC_ENDED; /* * End of line terminating an implicit block @@ -1872,7 +1873,7 @@ termp_quote_pre(DECL_ARGS) case MDOC_Do: /* FALLTHROUGH */ case MDOC_Dq: - term_word(p, "\\(lq"); + term_word(p, "\\(Lq"); break; case MDOC_En: if (NULL == n->norm->Es || @@ -1941,7 +1942,7 @@ termp_quote_post(DECL_ARGS) case MDOC_Do: /* FALLTHROUGH */ case MDOC_Dq: - term_word(p, "\\(rq"); + term_word(p, "\\(Rq"); break; case MDOC_En: if (n->norm->Es == NULL || @@ -1989,9 +1990,8 @@ termp_eo_pre(DECL_ARGS) n->child->end != ENDBODY_NOT) term_word(p, "\\&"); else if (n->end != ENDBODY_NOT ? n->child != NULL : - n->parent->head->child != NULL && - (n->parent->body->child != NULL || - n->parent->tail->child != NULL)) + n->parent->head->child != NULL && (n->child != NULL || + (n->parent->tail != NULL && n->parent->tail->child != NULL))) p->flags |= TERMP_NOSPACE; return(1);