1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-25 02:18:08 +00:00

Merge pull request #212 from iammookli/master

http_load_: Support underscores in URLs
This commit is contained in:
Kenyon Ralph 2012-11-25 17:58:15 -08:00
commit 028275b3d2

View file

@ -185,7 +185,7 @@ sub get_fieldname{
# Same as get_fieldname except it doesn't substr
sub get_id{
my $url=$_[0];
$url =~ s/\W//g;
$url =~ s/[\W_]//g;
return $url;
}
@ -195,7 +195,7 @@ $debug && print "Scriptname: " . $scriptname . "\n";
#
# The filename format is http_load_X_Y where
# X: The line number in urls.txt
# X: The type of graph (elements, size, loadtime, ..)
# Y: The type of graph (elements, size, loadtime, ..)
my ($id,$type);
$0 =~ /http_load(?:_([^_]+)|)_(.+)\s*$/;