=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/mandoc/tbl_data.c,v retrieving revision 1.8 retrieving revision 1.9 diff -c -r1.8 -r1.9 *** src/usr.bin/mandoc/tbl_data.c 2011/01/25 12:24:26 1.8 --- src/usr.bin/mandoc/tbl_data.c 2011/02/10 00:06:30 1.9 *************** *** 1,4 **** ! /* $Id: tbl_data.c,v 1.8 2011/01/25 12:24:26 schwarze Exp $ */ /* * Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2011 Ingo Schwarze --- 1,4 ---- ! /* $Id: tbl_data.c,v 1.9 2011/02/10 00:06:30 schwarze Exp $ */ /* * Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2011 Ingo Schwarze *************** *** 25,35 **** #include "libmandoc.h" #include "libroff.h" ! static int data(struct tbl_node *, struct tbl_span *, ! int, const char *, int *); ! static struct tbl_span *newspan(struct tbl_node *, struct tbl_row *); - static int data(struct tbl_node *tbl, struct tbl_span *dp, int ln, const char *p, int *pos) --- 25,35 ---- #include "libmandoc.h" #include "libroff.h" ! static int data(struct tbl_node *, struct tbl_span *, ! int, const char *, int *); ! static struct tbl_span *newspan(struct tbl_node *, int, ! struct tbl_row *); static int data(struct tbl_node *tbl, struct tbl_span *dp, int ln, const char *p, int *pos) *************** *** 172,182 **** } static struct tbl_span * ! newspan(struct tbl_node *tbl, struct tbl_row *rp) { struct tbl_span *dp; dp = mandoc_calloc(1, sizeof(struct tbl_span)); dp->tbl = &tbl->opts; dp->layout = rp; dp->head = tbl->first_head; --- 172,183 ---- } static struct tbl_span * ! newspan(struct tbl_node *tbl, int line, struct tbl_row *rp) { struct tbl_span *dp; dp = mandoc_calloc(1, sizeof(struct tbl_span)); + dp->line = line; dp->tbl = &tbl->opts; dp->layout = rp; dp->head = tbl->first_head; *************** *** 222,232 **** rp && rp->first; rp = rp->next) { switch (rp->first->pos) { case (TBL_CELL_HORIZ): ! dp = newspan(tbl, rp); dp->pos = TBL_SPAN_HORIZ; continue; case (TBL_CELL_DHORIZ): ! dp = newspan(tbl, rp); dp->pos = TBL_SPAN_DHORIZ; continue; default: --- 223,233 ---- rp && rp->first; rp = rp->next) { switch (rp->first->pos) { case (TBL_CELL_HORIZ): ! dp = newspan(tbl, ln, rp); dp->pos = TBL_SPAN_HORIZ; continue; case (TBL_CELL_DHORIZ): ! dp = newspan(tbl, ln, rp); dp->pos = TBL_SPAN_DHORIZ; continue; default: *************** *** 244,250 **** assert(rp); ! dp = newspan(tbl, rp); if ( ! strcmp(p, "_")) { dp->pos = TBL_SPAN_HORIZ; --- 245,251 ---- assert(rp); ! dp = newspan(tbl, ln, rp); if ( ! strcmp(p, "_")) { dp->pos = TBL_SPAN_HORIZ;