]> dxcluster.org Git - spider.git/commitdiff
use IO::Socket::IP and fix null reply
authorDirk Koopman <djk@tobit.co.uk>
Mon, 14 Sep 2020 23:28:48 +0000 (01:28 +0200)
committerDirk Koopman <djk@tobit.co.uk>
Mon, 14 Sep 2020 23:28:48 +0000 (01:28 +0200)
perl/DXUDP.pm
perl/wsjtl.pl

index 01c3b3b0339e4e37dc353d9e469b2426bb353cbd..fda14c6f8680ff43e9f1b1cae09adfa641b16810 100644 (file)
@@ -108,7 +108,7 @@ sub start {
        my $host = $args->{LocalAddr} || $args->{host} || '0.0.0.0';
        my $port = $args->{LocalPort} || $args->{port} || 1234;
        
-    $socket = IO::Socket::INET6->new(
+    $socket = IO::Socket::IP->new(
                   LocalAddr => $host,
                   LocalPort => $port,
                   Proto => 'udp',
index f991366e34dc0a9b19ab943620194ac007dfd30f..7bfc8e7a8603ca45a211a78e6729f43bcb9c64d8 100755 (executable)
@@ -111,7 +111,7 @@ sub _udpread
    
        my $in = $wsjtx->handle($handle, $data, "$host:$port");
 
-       distribute($in);
+       distribute($in) if $in && length $in;
 }
 
 sub _accept