diff options
author | Niko Tyni <ntyni@iki.fi> | 2007-04-14 09:55:07 +0200 |
---|---|---|
committer | Niko Tyni <ntyni@iki.fi> | 2007-04-14 09:55:07 +0200 |
commit | aeb0b49ee5c442ce66e675c83dadf44ee0ea8bbf (patch) | |
tree | 8dd12c837ed676facb0a209c7876c5563da223e8 /lib/Smokeping | |
parent | e940342e10e11fdc8142e18bc64f31494c1268d3 (diff) | |
download | smokeping-aeb0b49ee5c442ce66e675c83dadf44ee0ea8bbf.tar.gz smokeping-aeb0b49ee5c442ce66e675c83dadf44ee0ea8bbf.tar.xz |
don't test usage if running as CGI
Diffstat (limited to 'lib/Smokeping')
-rw-r--r-- | lib/Smokeping/probes/Curl.pm | 3 | ||||
-rw-r--r-- | lib/Smokeping/probes/EchoPing.pm | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/lib/Smokeping/probes/Curl.pm b/lib/Smokeping/probes/Curl.pm index 2e2ef01..5f237ab 100644 --- a/lib/Smokeping/probes/Curl.pm +++ b/lib/Smokeping/probes/Curl.pm @@ -188,7 +188,8 @@ sub new { $self->_init if $self->can('_init'); - $self->test_usage; + # no need for this if running as a CGI + $self->test_usage unless $ENV{SERVER_SOFTWARE}; return $self; } diff --git a/lib/Smokeping/probes/EchoPing.pm b/lib/Smokeping/probes/EchoPing.pm index 097cfe6..94f31ac 100644 --- a/lib/Smokeping/probes/EchoPing.pm +++ b/lib/Smokeping/probes/EchoPing.pm @@ -74,7 +74,8 @@ sub new { $self->_init if $self->can('_init'); - $self->test_usage; + # no need for this if running as a CGI + $self->test_usage unless $ENV{SERVER_SOFTWARE}; return $self; } |