diff options
author | Graham Barr <gbarr@pobox.com> | 2003-05-20 10:45:03 +0000 |
---|---|---|
committer | Graham Barr <gbarr@pobox.com> | 2003-05-20 10:45:03 +0000 |
commit | 220861a053637f0e55f572c85221a275b710bc3f (patch) | |
tree | 587cc19dbba01abc267e5b2d25a0b9c1c65cfd6b | |
parent | ee22a3815bb223871aded4e82c7d850e9ca6b5ca (diff) | |
download | perl-libnet-220861a053637f0e55f572c85221a275b710bc3f.tar.gz |
Net::NNTP
- Prevent instance methods being called as class methods when debug is turned on
-rw-r--r-- | Net/NNTP.pm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Net/NNTP.pm b/Net/NNTP.pm index 521ccf1..1b5081e 100644 --- a/Net/NNTP.pm +++ b/Net/NNTP.pm @@ -14,7 +14,7 @@ use Carp; use Time::Local; use Net::Config; -$VERSION = "2.21"; # $Id: //depot/libnet/Net/NNTP.pm#15 $ +$VERSION = "2.22"; # $Id: //depot/libnet/Net/NNTP.pm#16 $ @ISA = qw(Net::Cmd IO::Socket::INET); sub new @@ -87,7 +87,7 @@ sub debug_text my $inout = shift; my $text = shift; - if(($nntp->code == 350 && $text =~ /^(\S+)/) + if((ref($nntp) and $nntp->code == 350 and $text =~ /^(\S+)/) || ($text =~ /^(authinfo\s+pass)/io)) { $text = "$1 ....\n" @@ -1113,6 +1113,6 @@ it under the same terms as Perl itself. =for html <hr> -I<$Id: //depot/libnet/Net/NNTP.pm#15 $> +I<$Id: //depot/libnet/Net/NNTP.pm#16 $> =cut |