http://qs321.pair.com?node_id=322916


in reply to How to Trap exit code from system calls

You could always just use a system call. Below is what the docs say about checking exit values and such.
Because system() and backticks block SIGINT and SIGQUIT, killing the p +rogram they're running doesn't actually interrupt your program. @args = ("command", "arg1", "arg2"); system(@args) == 0 or die "system @args failed: $?" You can check all the failure possibilities by inspecting $? like this +: $exit_value = $? >> 8; $signal_num = $? & 127; $dumped_core = $? & 128;

- Tom