Subject: | Memory leak in XS version |
Small test script attached.
Leak only in XS part, PurePerl part working fine.
Leak appear under perl5.8.0 and under 5.8.1.
It's realy-realy bad. Almost all software on our production server uses this module so memory is under pressure.
Best regards. Ruslan.
#!/usr/bin/perl -w
use strict;
#use Apache::Leak;
use Params::Validate qw(validate SCALAR ARRAYREF CODEREF);
Params::Validate::validation_options( allow_extra => 1 );
use vars qw($Logger $LogToFile $LogToFileNamed);
sub foo
{
my %p = validate( @_, { level => { type => SCALAR },
message => { type => SCALAR },
} );
warn "[".$p{level}."]:".$p{message}."";
};
#leak_test {
while(1) {
foo(level => 'debug', message => 'x' x 70);
};