=================================================================== RCS file: /cvs/mandoc/man_term.c,v retrieving revision 1.4 retrieving revision 1.7 diff -u -p -r1.4 -r1.7 --- mandoc/man_term.c 2009/03/26 16:23:22 1.4 +++ mandoc/man_term.c 2009/04/05 16:34:22 1.7 @@ -1,4 +1,4 @@ -/* $Id: man_term.c,v 1.4 2009/03/26 16:23:22 kristaps Exp $ */ +/* $Id: man_term.c,v 1.7 2009/04/05 16:34:22 kristaps Exp $ */ /* * Copyright (c) 2008, 2009 Kristaps Dzonsons * @@ -80,6 +80,9 @@ static const struct termact termacts[MAN_MAX] = { { pre_I, post_I }, /* I */ { pre_IR, NULL }, /* IR */ { pre_RI, NULL }, /* RI */ + { pre_PP, NULL }, /* br */ + { NULL, NULL }, /* na */ + { pre_I, post_I }, /* i */ }; static void print_head(struct termp *, @@ -280,15 +283,15 @@ pre_IP(DECL_ARGS) if (NULL == (nn = n->child)) return(1); - - /* FIXME - ignore the designator. */ - nn = nn->next; - if (MAN_TEXT != nn->type) errx(1, "expected text line argument"); - offs = (size_t)atoi(nn->string); - nn = nn->next; + if (nn->next) { + if (MAN_TEXT != nn->next->type) + errx(1, "expected text line argument"); + offs = (size_t)atoi(nn->next->string); + } else + offs = strlen(nn->string); p->flags |= TERMP_NOSPACE; p->offset += offs;