Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Hope the robed ones can help!my $pm = new Parallel::ForkManager(4); foreach my $bccperson (@bccppl) { $pm->run_on_start( sub { $scount++; print "Sending Msg:$mjobno:$scount:$bccperson\n"; } ); $pm->run_on_finish( sub { $xcount++; } ); $pm->start and next; my $msg = MIME::Lite->new( From => $from, To => $bccperson, Subject => $subject, Type => 'text', Data => $body ) || print "MIME::Lite new error: $bc +cperson\n"; MIME::Lite->send('smtp', '10.10.10.10', Timeout=>240); $msg->send() || print "Couldn't send to: $bccperson\n"; $pm->finish; } #End of foreach $bccperson $pm->wait_all_children; print "This Line prints Fine\n"; print "This line doesn't appear at all, no statements after the print + line above execute, how frustrating!!!\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Parallel Forkmanager - Code not being executed?
by ehdonhon (Curate) on Jul 01, 2002 at 22:00 UTC | |
|
Re: Parallel Forkmanager - Code not being executed?
by RMGir (Prior) on Jul 01, 2002 at 20:40 UTC | |
|
Re: Parallel Forkmanager - Code not being executed?
by yodabjorn (Monk) on Jul 02, 2002 at 00:58 UTC |