X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fdx.pl;h=18687a6843b5780758010684d68d8c9d3e8efaad;hb=536ca8cd5840f5b1f8e7329ce5025fd904621594;hp=d8dd56cbbd7ee76bf0507242d3eea7d9d8ee1ead;hpb=94c061b1299f01876a735555b30c6a9ca857e9e4;p=spider.git diff --git a/cmd/dx.pl b/cmd/dx.pl index d8dd56cb..18687a68 100644 --- a/cmd/dx.pl +++ b/cmd/dx.pl @@ -122,9 +122,11 @@ return (1, @out) unless $valid; my $ipaddr; -if ($self->conn->peerhost) { +if ($self->conn && $self->conn->peerhost) { my $addr = $self->conn->peerhost; $ipaddr = $addr unless !is_ipaddr($addr) || $addr =~ /^127\./ || $addr =~ /^::[0-9a-f]+$/; +} elsif ($self->inscript) { + $ipaddr = "script"; } # Store it here (but only if it isn't baddx)