apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject Re: EGAIN, EINTR et.al.
Date Tue, 30 Oct 2001 00:41:21 GMT
Dirk-Willem van Gulik <dirkx@covalent.net> writes:

> Right now we are trapping EACCESS and moving it to 'EAGAIN' for a flock().

since a couple of unices return EACCESS for the retriable
somebody-else-has-the-lock situation that most unices return EAGAIN


(bad reason coming on) testflock.c assumes
APR_STATUS_IS_EAGAIN(status) will tell you if somebody else has the lock

> But on some platforms you can get things like EWOULDBLOCK and EINTR too.
> In APR is there a convenient macro to figure out if the exit code is a
> 'hard' error (say EINVAL, EBADF, ENOTSUPP) or one to figure out if it is
> a retryable type error ?

certainly more stuff is needed here, but would probably be more
specific than is-hard-error or is-retriable-error or even
is-hard-file-lock-error or is-retriable-file-lock-error

Jeff Trawick | trawick@attglobal.net | PGP public key at web site:
             Born in Roswell... married an alien...

View raw message