in reply to or DIE adding line number to error
You could use unless and exit. And if you want to see why it fails you can add $!
unless(open(LOG, "< $file")){ print "Sorry could not open $file - $!","\n"; exit; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: or DIE adding line number to error
by thor (Priest) on Mar 10, 2005 at 05:38 UTC | |
by baztastic (Scribe) on Mar 10, 2005 at 21:35 UTC |