X-Git-Url: http://git.rot13.org/?p=virtual-ldap;a=blobdiff_plain;f=bin%2Fldap-koha.pl;h=e97e1efc2813012fcdb730755e08b2ba4ee86b1e;hp=d50ebbca4655db00bb2134fb11ffee9ec87d3091;hb=2b0deecf4e04a468229c83049ca0db5426a931fc;hpb=97697527827da534e72c5ed16d577df9ff21f837 diff --git a/bin/ldap-koha.pl b/bin/ldap-koha.pl index d50ebbc..e97e1ef 100755 --- a/bin/ldap-koha.pl +++ b/bin/ldap-koha.pl @@ -8,16 +8,16 @@ use IO::Socket; use lib 'lib'; use LDAP::Koha; -my $port = 2389; +my $listen = shift @ARGV || 'localhost:2389'; my $sock = IO::Socket::INET->new( Listen => 5, Proto => 'tcp', Reuse => 1, - LocalPort => $port, -) || die; + LocalAddr => $listen, +) || die "can't listen to $listen $!"; -warn "# listening on $port"; +warn "# listening on $listen"; my $sel = IO::Select->new($sock); my %Handlers;