Skip Menu |

This queue is for tickets about the POE-Component-IRC CPAN distribution.

Report information
The Basics
Id: 21058
Status: resolved
Worked: 20 min
Priority: 0/
Queue: POE-Component-IRC

People
Owner: BINGOS [...] cpan.org
Requestors: tom+cpan [...] iplod.net
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 4.97
Fixed in: (no value)



Subject: Plugin::ISupport returning incorrect PREFIXes
Some IRC servers seem to be issuing their PREFIX support as "@+" instead of "(ov)@+". This breaks the regex in ISupport.pm on line 91. This then causes $irc->isupport('PREFIX') to return a malformed hash in PoCo-IRC-STate and in some cases, causes Perl to die. Simple fix so far seems to be changing ISupport.pm: --- ISupport.pm 2006-08-18 13:31:38.000000000 +0930 +++ ISupport.new 2006-08-18 13:29:35.000000000 +0930 @@ -88,8 +88,9 @@ } } elsif ($key eq 'PREFIX') { - my ($k, $v) = $val =~ /\(([^)]+)\)(.*)/; - @{ $support->{$key} }{split //, $k} = split //, $v; + if ( my ($k, $v) = $val =~ /\(([^)]+)\)(.*)/ ){ + @{ $support->{$key} }{split //, $k} = split //, $v; + } } elsif ($key eq 'SILENCE') { $support->{$key} = length($val) ? $val : 'off';
Patch applied. Tests pass. Thanks.