summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorNiko Tyni <ntyni@iki.fi>2006-09-07 08:31:39 +0200
committerNiko Tyni <ntyni@iki.fi>2006-09-07 08:31:39 +0200
commitedbe6f2aa91d6d8d3ce6092aaf97fe5d08ecbbc1 (patch)
treeda92352fd34d603b43ba5f4b7a727203a68f955f /lib
parent364743d3606928e114cedc84e9d6c2f7cef7c7a3 (diff)
downloadsmokeping-edbe6f2aa91d6d8d3ce6092aaf97fe5d08ecbbc1.tar.gz
smokeping-edbe6f2aa91d6d8d3ce6092aaf97fe5d08ecbbc1.tar.xz
make the LDAP 'scope' option actually work.
Diffstat (limited to 'lib')
-rw-r--r--lib/Smokeping/probes/LDAP.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Smokeping/probes/LDAP.pm b/lib/Smokeping/probes/LDAP.pm
index 61d2957..a67e4a8 100644
--- a/lib/Smokeping/probes/LDAP.pm
+++ b/lib/Smokeping/probes/LDAP.pm
@@ -211,7 +211,7 @@ sub pingone {
}
local $IO::Socket::SSL::SSL_Context_obj; # ugly but necessary
$start = gettimeofday();
- my $ldap = new Net::LDAP($host, port => $port, version => $version, timeout => $timeout, scope => $scope)
+ my $ldap = new Net::LDAP($host, port => $port, version => $version, timeout => $timeout)
or do {
$self->do_log("connection error on $host: $!");
next;
@@ -238,7 +238,8 @@ sub pingone {
$ldap->unbind;
next;
};
- $mesg = $ldap->search(base => $base, filter => $filter, attrs => $attrsref);
+ $mesg = $ldap->search(base => $base, filter => $filter,
+ attrs => $attrsref, scope => $scope);
$mesg->code and do {
$self->do_log("filter error on $host: " . $mesg->error);
$ldap->unbind;