[rrd-developers] Re: Problem with current version of rrd_rpncalc.c

Tobias Oetiker oetiker at ee.ethz.ch
Sat Jul 13 20:37:56 MEST 2002


Today Alex van den Bogaerdt wrote:

>
> Hi,
>
> rrd_rpncalc.c uses DEF_NAM_FMT but this is never defined.
>
> This is introduced in version 1.10 of the file:
>     Index: rrd_rpncalc.c
>     ===================================================================
>     RCS file: /usr/cvs/rrdtool/program/src/rrd_rpncalc.c,v
>     retrieving revision 1.9
>     retrieving revision 1.10
>     diff -r1.9 -r1.10
>     274c274
>     <         else if (sscanf(expr, #VVV "(%[a-z0-9]s)",vname) == 1) { \
>     ---
>     >         else if (sscanf(expr, #VVV "(" DEF_NAM_FMT ")",vname) == 1) { \
>
> The simple solution would be to add the define to the file:
>     #define DEF_NAM_FMT "%29[_A-Za-z0-9]"
>
> Of course, that is not a good solution.  Another solution could be to
> include rrd_graph.h (where DEF_NAM_FMT currently is defined).
>
> However, the best solution may be to either move this define to rrd_tool.h
> or to rrd_rpncalc.h, or to create a new header file altogether
> (which then can be included in the suitable place).

damn ... I should rely compile after makeing these changes ...
while looking at the rrd_rpncalc code I
found a further instance of of DEF_NAM_FMT not being used fixed it
as well and added an inclusion of rrd_graph.h to the top of the
file

tobi

> Comments?
>

-- 
 ______    __   _
/_  __/_  / /  (_) Oetiker, ETZ J97, ETH, 8092 Zurich, Switzerland
 / // _ \/ _ \/ / phoneto:+41(0)1-632-5286  faxto:+41(0)1-632-1517
/_/ \.__/_.__/_/ oetiker at ee.ethz.ch http://google.com/search?q=tobi

--
Unsubscribe mailto:rrd-developers-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-developers-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-developers
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the rrd-developers mailing list