Merge pull request #1 from tunnelpr0/patch-1
enhancement: add IPv6 support to check plugin
This commit is contained in:
commit
824591f6c0
@ -1,8 +1,8 @@
|
|||||||
#!/usr/bin/perl
|
#!/usr/bin/perl
|
||||||
|
|
||||||
# Copyright 2016 XiCoN-FJS- @ fjs@xicon.de
|
# Copyright 2021 XiCoN-FJS- @ fjs@xicon.de
|
||||||
#
|
#
|
||||||
# Version: 0.1 (2016-01-02)
|
# Version: 0.2 (2021-11-12)
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
@ -19,6 +19,7 @@
|
|||||||
use strict;
|
use strict;
|
||||||
use warnings;
|
use warnings;
|
||||||
use IO::Socket;
|
use IO::Socket;
|
||||||
|
use IO::Socket::IP;
|
||||||
use IO::Socket::Timeout;
|
use IO::Socket::Timeout;
|
||||||
|
|
||||||
sub usage_die()
|
sub usage_die()
|
||||||
@ -44,7 +45,7 @@ if (not defined $timeout)
|
|||||||
}
|
}
|
||||||
|
|
||||||
# prepare the UDP connection
|
# prepare the UDP connection
|
||||||
my $ts3_sock = IO::Socket::INET->new(
|
my $ts3_sock = IO::Socket::IP->new(
|
||||||
Proto => 'udp',
|
Proto => 'udp',
|
||||||
PeerPort => $port,
|
PeerPort => $port,
|
||||||
PeerAddr => $host,
|
PeerAddr => $host,
|
||||||
|
Loading…
Reference in New Issue
Block a user