in reply to Re: Catching errors in closing lexical filehandles
in thread Catching errors in closing lexical filehandles
Regarding "you do your error checking on open, not close", this is not quite correct. Close can have errors, e.g. when the file is a pipe that has been closed on the other side.
And regarding die, in the first instance, I was using it as a token for "any appropriate error handling I might choose to apply here". In the second instance, you can (and I often do) achieve protection from termination by catching the die with an eval somewhere up the call train.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Catching errors in closing lexical filehandles
by TedPride (Priest) on Sep 27, 2004 at 08:11 UTC | |
by gaal (Parson) on Sep 27, 2004 at 09:22 UTC |