in reply to vanishing system call
system returns 0 if there are no errors, the opposite of most other operations.
$? contains the error for daughter processes
. Anyway, here is one way:
However, that being said, my preference would be to use Perl's sort for this.system(" cat $file | sort -t\\| +1 -2 > $file.out ") == 0 or die "Erro +r:$?\n";
--
Regards,
Helgi Briem
helgi AT decode DOT is
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: vanishing system call
by Aristotle (Chancellor) on Sep 23, 2002 at 17:32 UTC |