Do you know where your variables are? | |
PerlMonks |
Re: perl program return error code to kshby Corion (Patriarch) |
on Jun 24, 2014 at 11:20 UTC ( [id://1091038]=note: print w/replies, xml ) | Need Help?? |
die sets the exit code to a nonzero value, which you should find in $? in Perl and in ksh. Most likely you are calling perl with an intermediate shell, or maybe within a pipe construct:
Pipe constructs tend to lose the intermediate exit codes. If you can show the relevant part of the shell script where you call Perl and where you check for the error, maybe a solution will become apparent.
In Section
Seekers of Perl Wisdom
|
|