summaryrefslogtreecommitdiff
path: root/lib/Net/FTP.pm
diff options
context:
space:
mode:
authorGraham Barr <gbarr@pobox.com>2001-11-21 18:30:10 +0000
committerGraham Barr <gbarr@pobox.com>2001-11-21 18:30:10 +0000
commitc85707204c5d2a93ef021c88e43a92ba2d602304 (patch)
treefd54fe99acf0f241fb5dc38295da6edf0748e00a /lib/Net/FTP.pm
parentc6a5b0b7fcd5df8c39aef4485d955e2f2e47f6bc (diff)
downloadperl-c85707204c5d2a93ef021c88e43a92ba2d602304.tar.gz
Sync file with libnet-1.0901-tobe
p4raw-id: //depot/perl@13178
Diffstat (limited to 'lib/Net/FTP.pm')
-rw-r--r--lib/Net/FTP.pm16
1 files changed, 6 insertions, 10 deletions
diff --git a/lib/Net/FTP.pm b/lib/Net/FTP.pm
index ffa21e16af..d2780d31f6 100644
--- a/lib/Net/FTP.pm
+++ b/lib/Net/FTP.pm
@@ -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.61"; # $Id: //depot/libnet/Net/FTP.pm#61 $
+$VERSION = "2.62"; # $Id: //depot/libnet/Net/FTP.pm#64 $
@ISA = qw(Exporter Net::Cmd IO::Socket::INET);
# Someday I will "use constant", when I am not bothered to much about
@@ -142,11 +142,7 @@ sub quit
$ftp->close;
}
-sub DESTROY
-{
- my $ftp = shift;
- defined(fileno($ftp)) && $ftp->quit
-}
+sub DESTROY {}
sub ascii { shift->type('A',@_); }
sub binary { shift->type('I',@_); }
@@ -310,7 +306,7 @@ sub login {
($ruser,$pass,$acct) = $rc->lpa()
if ($rc);
- $pass = "-" . (eval { (getpwuid($>))[0] } || $ENV{NAME} ) . '@'
+ $pass = '-anonymous@'
if (!defined $pass && (!defined($ruser) || $ruser =~ /^anonymous/o));
}
@@ -1200,7 +1196,7 @@ Net::FTP - FTP Client class
use Net::FTP;
$ftp = Net::FTP->new("some.host.name", Debug => 0);
- $ftp->login("anonymous",'me@here.there');
+ $ftp->login("anonymous",'-anonymous@');
$ftp->cwd("/pub");
$ftp->get("that.file");
$ftp->quit;
@@ -1517,7 +1513,7 @@ C<put_unique> and those that do not require data connections.
=item port ( [ PORT ] )
Send a C<PORT> command to the server. If C<PORT> is specified then it is sent
-to the server. If not, the a listen socket is created and the correct information
+to the server. If not, then a listen socket is created and the correct information
sent to the server.
=item pasv ()
@@ -1718,6 +1714,6 @@ under the same terms as Perl itself.
=for html <hr>
-I<$Id: //depot/libnet/Net/FTP.pm#61 $>
+I<$Id: //depot/libnet/Net/FTP.pm#64 $>
=cut