Ah a red herring - it's not hashes at all! I'm changing values in a large hash as I loop through files. The problem occurs when I come to create the key for the hash. The following code works properly on 5.6 but grows on 5.8. Delete the substitution line, and hey presto, no more leak. use strict;
my $ret = `ps v $$`;
print "$ret\n";
for ( 1 .. 1000 ){
my $key = ':PERSON-NUM(1:*):NI-NUM(1:*):';
for my $bb ( "PERSON-NUM", "NI-NUM" ){
if ( $key =~ /:$bb *\( *([0-9]+) *: *([0-9\*]+) *\) *:/ ){
$key =~ s/:$bb *\( *[0-9]+ *: *[0-9\*]+ *\) *:/:$bb=1:/;
}
}
}
$ret = `ps v $$`;
print "$ret\n";
Now I'm confused!
'I think the problem lies in the fact that your data
doesn't fit my program'.
|