# New Ticket Created by Hazel # Please include the string: [perl #118815] # in the subject line of all future correspondence about this issue. # <URL: https://rt.perl.org:443/rt3/Ticket/Display.html?id=118815 > ----------------------------------------------------------------- [Please describe your issue here] When a thread terminated abnormally ( ie a die ) erl is leaking memory use strict; use threads; sub dummy { die ; }; threads->create( \&dummy ); while( 1 ) { my @dead = threads->list( threads::joinable ); foreach my $t ( @dead ) { if( my $e = $t->error() ) { print "Error : $e\n" } $t->join; threads->create( \&dummy ); } } Quick output from `ps` haze 25229 66.0 11.0 400164 210952 pts/0 R+ 10:48 0:00 ./bin/perl haze 25229 88.5 28.1 720400 538220 pts/0 Rl+ 10:48 0:01 ./bin/perl haze 25229 85.6 39.2 927272 749800 pts/0 Rl+ 10:48 0:02 ./bin/perl haze 25229 84.2 49.5 1120988 947808 pts/0 Rl+ 10:48 0:03 ./bin/perl Replacing the die call in the dummy sub with a return does not trigger thisThread Previous | Thread Next