waste of resources ?
moshez at math.huji.ac.il
Tue Jun 8 00:03:03 CEST 1999
On 7 Jun 1999, Hrvoje Niksic wrote:
<about syscalls throwing EINTR and aborting>
> I don't know about Perl, but a good fix would be to have the
> interpreter do the hard work for us. If a system call fails and errno
> is EINTR, then the signal handler should be called, *and* the syscall
> should be restarted.
You can do the hard-work yourself, but once and for all:
except (IOError, os.error), detail:
if detail.args != errno.EINTR: raise
And just call myread(foo) instead of foo.read().
Where's the catch-22?
Moshe Zadka <mzadka at geocities.com>.
QOTD: My own exit is more likely to be horizontal then perpendicular.
More information about the Python-list