FIX: rrdtool v 1.2.6 COMMENT ':' not properly escaped

Anything that you think should be in Cacti.

Moderators: Developers, Moderators

Post Reply
Neptune
Posts: 4
Joined: Sun Oct 10, 2004 12:42 am

FIX: rrdtool v 1.2.6 COMMENT ':' not properly escaped

Post by Neptune »

To fix, apply this patch:

diff lib/rrd.php.orig lib/rrd.php
692c692
< $graph_legend .= "COMMENT:\"From " . date($graph_date, $graph_data_array["graph_start"]) . " To " . date($graph_date, $graph_data_array["graph_end"]) . "\\c\"" . RRD_NL . "COMMENT:\" \\n\"" . RRD_NL;
---
> $graph_legend .= "COMMENT:\"From " . str_replace(":", "\:",date($graph_date, $graph_data_array["graph_start"])) . " To " . str_replace(":", "\:",date($graph_date, $graph_data_array["graph_end"])) . "\\c\"" . RRD_NL . "COMMENT:\" \\n\"" . RRD_NL;
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

How about setting the correct version in your cacti settings for rrdtool, which will fix the problem.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest