Skip Menu |

This queue is for tickets about the NetxAP CPAN distribution.

Report information
The Basics
Id: 346
Status: new
Priority: 0/
Queue: NetxAP

People
Owner: Nobody in particular
Requestors: guennewi [...] ls6.cs.uni-dortmund.de
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: (no value)
Fixed in: (no value)



Subject: NetXAP -- solved some bugs and typos in Net::IMAP
Distribution name: NetXAP-0.02 Perl version: Perl >= 5.5.x The following bugs have been found and fixed by me: 1. perl Makefile.PL complains about missing module MD5. The module has been renamed to Digest::MD5. 2. The IMAP banner parsing doesn't return the correct information about the support of IMAP4rev1. Use the CAPABILITIES command as the standard says. (Tested with Cyrus-IMAPD Version 1.6.19 up to 2.0.16) 3. In Net::IMAP::Search::new you should check for an empty answer of the server, else perl complains about "Use of uninitialized value...". 4. Comment out a print command, which prints each found article. 5. Fixed typo in Net::IMAP:Acl::new -- lc{$key} instead of lc($key). 6. Fixed many typos in the POD. Michael Guennewig
diff -dur NetxAP-0.02/Makefile.PL NetxAP-0.02-new/Makefile.PL --- NetxAP-0.02/Makefile.PL Sun Oct 3 16:46:30 1999 +++ NetxAP-0.02-new/Makefile.PL Tue Mar 12 11:07:29 2002 @@ -7,7 +7,7 @@ VERSION => '0.02', DISTNAME => 'NetxAP', PREREQ_PM => { MIME::Base64 => 2.11, - MD5 => 2.01, + Digest::HMAC_MD5 => 1.01, }, 'dist' => { COMPRESS => 'gzip', SUFFIX => '.gz' }, ); diff -dur NetxAP-0.02/Net/IMAP.pm NetxAP-0.02-new/Net/IMAP.pm --- NetxAP-0.02/Net/IMAP.pm Sun Oct 3 16:56:21 1999 +++ NetxAP-0.02-new/Net/IMAP.pm Tue Mar 12 11:08:41 2002 @@ -233,6 +233,8 @@ return undef; } + return undef unless (defined $self->{Capabilities}{IMAP4REV1}); + return $self; } @@ -263,14 +265,6 @@ } elsif (($list->[0] ne '*') || ($list->[1] !~ /^ok$/i)) { return undef; } - my $supports_imap4rev1 = 0; - for my $item (@{$list}) { - $supports_imap4rev1++ if ($item =~ /^imap4rev1$/i); - } - unless ($supports_imap4rev1) { - $self->close_connection; - return undef; - } $self->{Banner} = $list; @@ -2091,7 +2085,7 @@ my %hash = @{Net::xAP->parse_fields($str)->[0]}; for my $key (keys %hash) { my $lckey = lc($key); - print "$lckey $hash{$key}\n"; + #print "$lckey $hash{$key}\n"; if ($lckey eq 'envelope') { $self->{Items}{$lckey} = Net::IMAP::Envelope->new($hash{$key}); } elsif (($lckey eq 'bodystructure') || ($lckey eq 'body')) { @@ -2204,8 +2198,12 @@ $self->{Parent} = $parent; - for my $item (split(/\s/, $str)) { - $self->{Msgnums}{$item}++; + if (defined $str) { + for my $item (split(/\s/, $str)) { + $self->{Msgnums}{$item}++; + } + } else { + $self->{Msgnums} = (); } return $self; @@ -2424,7 +2422,7 @@ =head1 ACL -This is a container for C<acl> responses> +This is a container for C<acl> responses. =head2 mailbox @@ -2460,7 +2458,7 @@ $self->{Mailbox} = shift(@fields); my %hash = @fields; for my $key (keys %hash) { - $self->{Identifiers}{lc{$key}} = $hash{$key}; + $self->{Identifiers}{lc($key)} = $hash{$key}; } return $self; @@ -2524,7 +2522,7 @@ =head1 Myrights -This is a container for C<myrights> responses> +This is a container for C<myrights> responses. =head2 mailbox @@ -2808,7 +2806,7 @@ =head1 Multipart -This is a container for C<BodyStructure objects that are multipart entities. +This is a container for C<BodyStructure> objects that are multipart entities. =head2 parts @@ -2903,12 +2901,12 @@ =head2 envelope -If the MIME content type is C<message/rfc822, returns a +If the MIME content type is C<message/rfc822>, returns a C<Net::IMAP::Envelope> object, otherwise returns undef. =head2 bodystructure -If the MIME content type is C<message/rfc822, returns a +If the MIME content type is C<message/rfc822>, returns a C<Net::IMAP::BodyStructure> object, otherwise returns undef. =head2 md5