in reply to Perl Pipeline exception handling

Hi perl_diver,

The convention is that when a program fails it exits with a nonzero exit code. Assuming your "PipeLine.pm" follows this convention, success would be indicated by system returning zero, and failure by a nonzero return value. How to inspect the exit code (which is also stored in $?) is also documented in system. So you could write your code like this (untested):

foreach my $f (@Folders) { if ( system("PipeLine.pm",$f,"my.Config.ini") != 0 ) { warn "Failure when processing file $f, \$?=$?\n"; } }

Hope this helps,
-- Hauke D