Help with my brute force method

C

Charles DeRykus

that takes care of it most of the time....
[snipped]


However, the automatic closing does not die or warn upon failure.
If you open an actual file for reading, this probably isn't a problem,
but if you open a pipe command, it can be. Since one of the things I like
about perl the ready ability to change file opens into pipe opens, I am
careful to avoid situations where doing just that would create hard to find
bugs.
Thanks for raising the issue. After suffering a severe exit wound
once when a partition filled, I have great affinity for T.Christ's
Cookbook advise:

"Those implicit closes are for convenience, not stability,
because they don't tell you whether the system call
succeeded or failed. Not all closes succeed. Even a
close on a read-only file can fail. For instance, you
could lose access to the device because of a network
outage. It's even more important to check the close if
the file was opened for writing. Otherwise you wouldn't
notice if the disk filled up."
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,527
Members
45,000
Latest member
MurrayKeync

Latest Threads

Top