in reply to Re^2: Perl variable scoping between functionsin thread Perl variable scoping between functions
Why are you calling the sub twice?