From: oetiker Date: Sun, 13 Aug 2006 16:07:36 +0000 (+0000) Subject: can't define new variables in the middle of the code (unless everyone was using c99... X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=4858fd0949b99d59877c80fd33aca6af88d9b8fd;p=rrdtool.git can't define new variables in the middle of the code (unless everyone was using c99 which is not the case) git-svn-id: svn://svn.oetiker.ch/rrdtool/branches/1.2/program@870 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/src/rrd_tool.c b/src/rrd_tool.c index cf29cd9..f393f86 100644 --- a/src/rrd_tool.c +++ b/src/rrd_tool.c @@ -689,12 +689,12 @@ int HandleInputLine(int argc, char **argv, FILE* out) printf (" <%s>", DATA_ROW_TAG); printf ("<%s>%lu", COL_TIME_TAG, ti, COL_TIME_TAG); for (j = 0; j < col_cnt; j++) { + rrd_value_t newval = DNAN; if (enumds == 1) snprintf(vtag,15,"%s%lu", COL_DATA_TAG, j); else snprintf(vtag,15,"%s",COL_DATA_TAG); - rrd_value_t newval = DNAN; newval = *ptr; if(isnan(newval)){ printf("<%s>NaN", vtag,vtag);