]> dxcluster.org Git - spider.git/commitdiff
fix ip address detection in PC92
authorDirk Koopman <djk@tobit.co.uk>
Fri, 21 Jan 2022 18:12:31 +0000 (18:12 +0000)
committerDirk Koopman <djk@tobit.co.uk>
Fri, 21 Jan 2022 18:12:31 +0000 (18:12 +0000)
perl/DXProtHandle.pm

index 6f4fbd08d92c3bca3513e7189111ede1aa982e8d..2b0a491ba6d983eaffc08d81de5a3f1c949866f1 100644 (file)
@@ -1571,8 +1571,9 @@ sub _decode_pc92_call
        my $version = $part[1] || 0;
        my $build = $part[2] || 0;
        my $ip = $part[3] || '';
-       
-       if (is_ipaddr($version)) {
+
+       # remember that, at this stage, IPV6 addresses have : replaced by ,
+       if (length $version > 4 && $version =~ /[,\.][\da-f]{1,4}/i) {
                $ip = $version;
                $version = 0;
        }