I might add that while it's uncommon to see it done here, checking the return value of print can be useful. Consider this:
perl -e 'print BADHANDLE "Hello world.\n" or die $!'
...output...
Bad file descriptor at -e line 1.
...which is kinda nice information to know.
Dave
In reply to Re^2: opened file being overwritten
by davido
in thread opened file being overwritten
by perishowl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |