Code

contrib/exec-munin.px: Use the "PUTVAL" command explicitly.
authorFlorian Forster <octo@leeloo.lan.home.verplant.org>
Mon, 5 Jul 2010 07:40:33 +0000 (09:40 +0200)
committerFlorian Forster <octo@leeloo.lan.home.verplant.org>
Mon, 5 Jul 2010 07:40:33 +0000 (09:40 +0200)
contrib/exec-munin.px

index 907ea9bccac0ad3bc68b2779216500c311d1b558..b57601a3054aa9c99c8022c384d869f595828882 100755 (executable)
@@ -206,8 +206,11 @@ sub execute_script
       my $field = $1;
       my $value = $2;
       my $type = (defined ($TypeMap->{$field})) ? $TypeMap->{$field} : $field;
+      my $ident = "$host/munin-$pinst/$type";
 
-      print "$host/munin-$pinst/$type interval=$Interval $time:$value\n";
+      $ident =~ s/"/\\"/g;
+
+      print qq(PUTVAL "$ident" interval=$Interval $time:$value\n);
     }
   }