[mrtg-developers] Re: perl compatibity
Simon Leinen
simon at limmat.switch.ch
Thu Jun 19 15:38:57 MEST 2003
I don't like this change too much (and it's a change to my code):
> --- SNMP_Session.pm Wed Jun 18 15:37:10 2003
> +++ SNMP_Session.pm-patched Wed Jun 18 15:48:19 2003
> @@ -124,7 +124,13 @@
> if (eval {require Socket6;} &&
> eval {require IO::Socket::INET6; IO::Socket::INET6->VERSION("1.26");}) {
> import Socket6;
> +
> + # Disable strict subs to stop old versions of perl from
> + # complaining about AF_INET6 when Socket6 is not available
> + no strict "subs";
> $ipv6_addr_len = length(pack_sockaddr_in6(161, inet_pton(AF_INET6, "::1")));
> + use strict "subs";
> +
> $SNMP_Session::ipv6available = 1;
> }
> }
Why don't you simply write "AF_INET6()" instead of "AF_INET6"?
Doesn't that work on all versions?
--
Simon.
--
Unsubscribe mailto:mrtg-developers-request at list.ee.ethz.ch?subject=unsubscribe
Help mailto:mrtg-developers-request at list.ee.ethz.ch?subject=help
Archive http://www.ee.ethz.ch/~slist/mrtg-developers
More information about the mrtg-developers
mailing list