in reply to Backup script: how can I force this to report errors?
I get:perl -e 'system ("tar cf /home/yup/yup.tar .") and die "Oops: $?\n";'
So $? is definitely set, and tar's exit code was 512 >> 8 = 2. Are you sure _barf does not get called?tar: /home/yup/yup.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now Oops: 512
As an aside, I assume you predeclare _barf in the omitted initialisation section, as the way the script is written the call to _barf will not work.
CU
Robartes-
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Backup script: how can I force this to report errors?
by LAI (Hermit) on Mar 20, 2003 at 17:21 UTC |