1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 02:51:03 +00:00

properly escape value output

This commit is contained in:
Antoine Beaupré 2012-03-09 02:57:19 -05:00
parent 2fae403dd2
commit f6f1b07a92

View file

@ -146,10 +146,14 @@ for my $host (@hosts) {
print "multigraph relayd_avail\n\n"; print "multigraph relayd_avail\n\n";
for my $host (@hosts) { for my $host (@hosts) {
print "$host.value " . ($avail{$host} || 'NaN'). "\n"; my $clean = clean_fieldname($host);
$clean = clean_fieldname('host'.$host) unless ($clean ne '_');
print "$clean.value " . ($avail{$host} || 'NaN'). "\n";
} }
print "\nmultigraph relayd_incidents\n\n"; print "\nmultigraph relayd_incidents\n\n";
for my $host (@hosts) { for my $host (@hosts) {
print "$host.value " . ($down{$host} || 0). "\n"; my $clean = clean_fieldname($host);
$clean = clean_fieldname('host'.$host) unless ($clean ne '_');
print "$clean.value " . ($down{$host} || 0). "\n";
} }