enhancement: add IPv6 support to check plugin

This commit is contained in:
tunnelpr0 2021-11-12 19:16:11 +01:00 committed by GitHub
parent 7a6dcd78f0
commit 1c76ec92eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,6 +19,7 @@
use strict;
use warnings;
use IO::Socket;
use IO::Socket::IP;
use IO::Socket::Timeout;
sub usage_die()
@ -44,7 +45,7 @@ if (not defined $timeout)
}
# prepare the UDP connection
my $ts3_sock = IO::Socket::INET->new(
my $ts3_sock = IO::Socket::IP->new(
Proto => 'udp',
PeerPort => $port,
PeerAddr => $host,