Skip Menu |

This queue is for tickets about the NetxAP CPAN distribution.

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

People
Owner: Nobody in particular
Requestors: ntyni [...] iki.fi
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.02
Fixed in: 0.02



Subject: getquota() broken
Hi, Using the getquota() method of Net::IMAP doesn't return useful data. The string returned from Cyrus as a result of a getquota call is as follows: --> 3 getquota user.xyz <-- * QUOTA user.xyz (STORAGE 53 51200) The data structure created within Net::IMAP from this is: 'Quota' => { 'array(0x83c88d0)' => [ undef, undef ] }, Where it should be: 'Quota' => { 'STORAGE' => [ 53, 51200 ] }, I'm attaching a proposed patch for this. This bug and the patch were originally reported in Debian bug #366480, http://bugs.debian.org/366480 , by Mike Beattie. Cheers, -- Niko Tyni ntyni@iki.fi
Subject: quota.patch
--- Net/IMAP.pm 2006/05/13 18:25:33 1.1 +++ Net/IMAP.pm 2006/05/13 18:28:49 @@ -2611,8 +2611,8 @@ my @fields = @{Net::xAP->parse_fields($str)}; $self->{QuotaRoot} = shift(@fields); while (@fields) { - my ($resource, $usage, $limit) = splice(@fields, 0, 3); - $self->{Quota}{lc($resource)} = [$usage, $limit]; + my ($resource, $usage, $limit) = splice(@{$fields[0]}, 0, 3); + $self->{Quotas}{lc($resource)} = [$usage, $limit]; } return $self;