diff options
Diffstat (limited to 'regress/sys/kern/splice/error-idle-EINVAL.pl')
-rwxr-xr-x | regress/sys/kern/splice/error-idle-EINVAL.pl | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/regress/sys/kern/splice/error-idle-EINVAL.pl b/regress/sys/kern/splice/error-idle-EINVAL.pl deleted file mode 100755 index 42f5c1a818a..00000000000 --- a/regress/sys/kern/splice/error-idle-EINVAL.pl +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/bin/perl -# test EINVAL for splicing with negative idle timeout - -use Errno; -use IO::Socket; -use BSD::Socket::Splice "SO_SPLICE"; -use Config; - -my $sl = IO::Socket::INET->new( - Proto => "tcp", - Listen => 5, - LocalAddr => "127.0.0.1", -) or die "socket listen failed: $!"; - -my $s = IO::Socket::INET->new( - Proto => "tcp", - PeerAddr => $sl->sockhost(), - PeerPort => $sl->sockport(), -) or die "socket failed: $!"; - -my $ss = IO::Socket::INET->new( - Proto => "tcp", - PeerAddr => $sl->sockhost(), - PeerPort => $sl->sockport(), -) or die "socket splice failed: $!"; - -my $packed; -if ($Config{longsize} == 8) { - $packed = pack('iiiiiiii', $ss->fileno(),0,0,0,-1,-1,-1,-1); -} else { - $packed = pack('iiiii', $ss->fileno(),0,0,-1,-1); -} -$s->setsockopt(SOL_SOCKET, SO_SPLICE, $packed) - and die "splice to unconnected socket succeeded"; -$!{EINVAL} - or die "error not EINVAL: $!" |