diff options
author | Niko Tyni <ntyni@iki.fi> | 2006-07-09 10:06:42 +0200 |
---|---|---|
committer | Niko Tyni <ntyni@iki.fi> | 2006-07-09 10:06:42 +0200 |
commit | 24aad364c78d190bdb371d0f19295cbecfc04ecd (patch) | |
tree | e23a2ad04629e3b56a382fb350116d2c7fbc2289 /lib | |
parent | bc44b6eb6edf099dbd8f2ba40ce7ed9e03462add (diff) | |
download | smokeping-24aad364c78d190bdb371d0f19295cbecfc04ecd.tar.gz smokeping-24aad364c78d190bdb371d0f19295cbecfc04ecd.tar.xz |
Merge a change from the 2.0 tree.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Smokeping.pm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Smokeping.pm b/lib/Smokeping.pm index 0236772..557f506 100644 --- a/lib/Smokeping.pm +++ b/lib/Smokeping.pm @@ -1169,10 +1169,11 @@ sub update_rrds($$$$$) { foreach my $addr (map {$_ ? (split /\s*,\s*/,$_) : ()} $cfg->{Alerts}{to},$tree->{alertee},$cfg->{Alerts}{$_}{to}){ next unless $addr; if ( $addr =~ /^\|(.+)/) { + my $cmd = $1; if ($edgetrigger) { - system $1,$_,$line,$loss,$rtt,$tree->{host}, ($what =~/raise/); + system $cmd,$_,$line,$loss,$rtt,$tree->{host}, ($what =~/raise/); } else { - system $1,$_,$line,$loss,$rtt,$tree->{host}; + system $cmd,$_,$line,$loss,$rtt,$tree->{host}; } } elsif ( $addr =~ /^snpp:(.+)/ ) { sendsnpp $1, <<SNPPALERT; |