aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--debian/changelog2
-rwxr-xr-xmunin-plugin5
2 files changed, 5 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index d069ae9..c561f18 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,8 @@
sitesummary (0.0.71) UNRELEASED; urgency=low
* Make sure 'site-summary -l' report handle hosts without a site set.
+ * Make munin plugin more robust, by not mapping 'illegal' characters
+ in site names to _.
-- Petter Reinholdtsen <pere@debian.org> Sat, 26 Nov 2011 21:52:32 +0100
diff --git a/munin-plugin b/munin-plugin
index a0899db..8c18a87 100755
--- a/munin-plugin
+++ b/munin-plugin
@@ -50,8 +50,9 @@ if (!$ARGV[0]) {
sub label2key {
my $label = shift;
- $label =~ s/[^a-zA-Z0-9_]+/_/g;
- $label =~ s/^_+//;
+ # Removing illegal characters. Apparently using '_' as a
+ # replacement character break graph generation with version 1.2.5.
+ $label =~ s/[^a-zA-Z0-9]+//g;
return $label;
}