Skip Menu |
 

This queue is for tickets about the IO-Socket-IP CPAN distribution.

Report information
The Basics
Id: 119780
Status: resolved
Priority: 0/
Queue: IO-Socket-IP

People
Owner: Nobody in particular
Requestors: XENU [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 0.39



Subject: [PATCH] CAN_DISABLE_V6ONLY crashes under dragonfly
Download (untitled) / with headers
text/plain 473b
Hello, CAN_DISABLE_V6ONLY crashes with "Cannot setsockopt() - Operation not supported" under DragonFly BSD. Excerpt from "man ip6" from dragonfly: Show quoted text
>IPV6_V6ONLY int * > Get or set whether only IPv6 connections can be made to this > socket. For wildcard sockets, this can restrict connections to > IPv6 only. With DragonFly, the socket option cannot be set to 0 > (which will result in returning EOPNOTSUPP).
All tests pass when attached patch is applied.
Subject: io_socket_ip_dfly.patch
--- IO-Socket-IP-0.38.orig/lib/IO/Socket/IP.pm 2016-08-02 19:37:26.000000000 +0200 +++ IO-Socket-IP-0.38.new/lib/IO/Socket/IP.pm 2017-01-10 02:13:18.000000000 +0100 @@ -31,7 +31,7 @@ my $AF_INET6 = eval { Socket::AF_INET6() }; # may not be defined my $AI_ADDRCONFIG = eval { Socket::AI_ADDRCONFIG() } || 0; use POSIX qw( dup2 ); -use Errno qw( EINVAL EINPROGRESS EISCONN ENOTCONN ETIMEDOUT EWOULDBLOCK ); +use Errno qw( EINVAL EINPROGRESS EISCONN ENOTCONN ETIMEDOUT EWOULDBLOCK EOPNOTSUPP ); use constant HAVE_MSWIN32 => ( $^O eq "MSWin32" ); @@ -154,7 +154,7 @@ if( setsockopt $testsock, IPPROTO_IPV6, IPV6_V6ONLY, 0 ) { return $can_disable_v6only = 1; } - elsif( $! == EINVAL ) { + elsif( $! == EINVAL || $! == EOPNOTSUPP ) { return $can_disable_v6only = 0; } else {
Download (untitled) / with headers
text/plain 119b
On Mon Jan 09 20:22:48 2017, XENU wrote: Show quoted text
> All tests pass when attached patch is applied.
Looks good. -- Paul Evans


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.