diff options
author | Graham Barr <gbarr@pobox.com> | 2003-09-25 09:22:26 +0000 |
---|---|---|
committer | Graham Barr <gbarr@pobox.com> | 2003-09-25 09:22:26 +0000 |
commit | 3a232eab88d61a03e37a92da96213fb763589b0c (patch) | |
tree | 9e48ba8293d683ac29bcd1cc2e213e5b71d42dc2 | |
parent | ce09c12b3449b9120c3ff5c71f54447eeb1be0a4 (diff) | |
download | perl-libnet-3a232eab88d61a03e37a92da96213fb763589b0c.tar.gz |
Net::FTP
- Allow spaces after the file size in the response to SIZE
-rw-r--r-- | Net/FTP.pm | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -22,7 +22,7 @@ use Net::Config; use Fcntl qw(O_WRONLY O_RDONLY O_APPEND O_CREAT O_TRUNC); # use AutoLoader qw(AUTOLOAD); -$VERSION = "2.71"; # $Id: //depot/libnet/Net/FTP.pm#78 $ +$VERSION = "2.72"; # $Id: //depot/libnet/Net/FTP.pm#79 $ @ISA = qw(Exporter Net::Cmd IO::Socket::INET); # Someday I will "use constant", when I am not bothered to much about @@ -206,7 +206,7 @@ sub size { my $io; if($ftp->supported("SIZE")) { return $ftp->_SIZE($file) - ? ($ftp->message =~ /(\d+)$/)[0] + ? ($ftp->message =~ /(\d+)\s*$/)[0] : undef; } elsif($ftp->supported("STAT")) { @@ -1767,6 +1767,6 @@ under the same terms as Perl itself. =for html <hr> -I<$Id: //depot/libnet/Net/FTP.pm#78 $> +I<$Id: //depot/libnet/Net/FTP.pm#79 $> =cut |