kamrul has asked for the wisdom of the Perl Monks concerning the following question:
My code is like below:
On TERM signal im trying to wait till all threads are ended. However, whenever I pass TERM signal my program gets terminated with an error "Segmentation fault" How to fix this ?my @threads = (); $SIG{'TERM'} = sub { foreach(@threads){ $_->join(); } }; push @threads, threads->create(proc1); push @threads, threads->create(proc2);
Back to
Seekers of Perl Wisdom