Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Getopt-Long-Descriptive CPAN distribution.

Report information
The Basics
Id: 64711
Status: resolved
Priority: 0/
Queue: Getopt-Long-Descriptive

People
Owner: Nobody in particular
Requestors: abraxxa [...] cpan.org
Cc:
AdminCc:

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



Subject: memory leak when run without all required args
doesn't happen with 0.086. The following script shows the problem: #!/usr/bin/env perl use strict; use warnings; use Getopt::Long::Descriptive; my ( $opt, $usage ) = describe_options( '%c %o', [ 'mode|m=s', "1234567890123456789012345678901234567890123456789012", { default => 'all' } ], [ 'startdate|s=s', "from which date (e.g. 2006-06-26)", { required => 1 } ], [ 'enddate|e=s', "to which date (e.g. 2006-07-26)", { required => 1 } ], [ 'help', "print usage message and exit" ], ); print( $usage->text ), exit if $opt->help; If you remove one char from "1234567890123456789012345678901234567890123456789012" the memory leak doesn't happen.
On Wed Jan 12 07:55:20 2011, ABRAXXA wrote: Show quoted text
> doesn't happen with 0.086. > > The following script shows the problem:
Infinite loops are not memory leaks. This also has nothing to do with the presence or absence of required arguments. The code that wraps documentation strings doesn't handle the case where there are more non-space characters than its line length (somewhere around 70 characters).
fixed in 0.88