diff options
author | Daniel Stenberg <daniel@haxx.se> | 2005-05-02 11:31:15 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2005-05-02 11:31:15 +0000 |
commit | 02ae3c2810a58ba4420417f914835314a6c56377 (patch) | |
tree | 5af8c32714ec41491a84f7f8fe9c356ace28774c | |
parent | 669ebb5f7189089fd3fca1e7d3b70d8a8e407946 (diff) |
read from the open2 filehandle with sysread, not <handle>
-rw-r--r-- | tests/ftpserver.pl | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/ftpserver.pl b/tests/ftpserver.pl index 77c800221..4c7643ad7 100644 --- a/tests/ftpserver.pl +++ b/tests/ftpserver.pl @@ -541,7 +541,9 @@ sub PASV_command { "./server/sockfilt --port 0 --logfile log/sockdata$ftpdnum$ext.log --pidfile .sockdata$ftpdnum$ext.pid $ipv6"); print DWRITE "PING\n"; - my $pong = <DREAD>; + my $pong; + + sysread(DREAD, $pong, 5) || die; if($pong !~ /^PONG/) { kill(9, $slavepid); @@ -668,7 +670,8 @@ sub PORT_command { "./server/sockfilt --connect $port --logfile log/sockdata$ftpdnum$ext.log --pidfile .sockdata$ftpdnum$ext.pid $ipv6"); print DWRITE "PING\n"; - my $pong = <DREAD>; + my $pong; + sysread DREAD, $pong, 5; if($pong !~ /^PONG/) { logmsg "Failed sockfilt for data connection\n"; |