Skip Menu |

This queue is for tickets about the Lingua-EN-Titlecase CPAN distribution.

Report information
The Basics
Id: 42545
Status: resolved
Worked: 30 min
Priority: 0/
Queue: Lingua-EN-Titlecase

People
Owner: ashley [...] cpan.org
Requestors: blom [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.11
Fixed in: (no value)



Subject: Module segfaults with digit-only input
Parsing breaks if (second) input consists solely of digits. To reproduce: Script -------- use Lingua::EN::Titlecase; my $tc = Lingua::EN::Titlecase->new('Test test'); print $tc->title(), $/; $tc->title('2001'); print $tc->title(), $/; -------- Output: -------- Test Test Deep recursion on subroutine "Lingua::EN::Titlecase::title" at /usr/local/share/perl/5.10.0/Lingua/EN/Titlecase.pm line 18. Deep recursion on subroutine "Lingua::EN::Titlecase::_parse" at /usr/local/share/perl/5.10.0/Lingua/EN/Titlecase.pm line 150. Deep recursion on subroutine "Lingua::EN::Titlecase::lexer" at /usr/local/share/perl/5.10.0/Lingua/EN/Titlecase.pm line 174. Deep recursion on anonymous subroutine at /usr/local/share/perl/5.10.0/Lingua/EN/Titlecase.pm line 207. Segmentation fault -------- -- B10m
Sorry this took so long. Gmail put it in my spam folder, I found it accidentally. :( Weird bug. Found another small problem and did a little optimization here and there, I think, to go with this. Added a test to make sure this is fixed and stays that way. 0.12 on the way up in a few.