On Mon, Jun 2, 2008 at 8:20 AM, Stephen Gran <[EMAIL PROTECTED]> wrote:
> perl should clear errno before going into a function where the API
> depends on checking it afterwards.  Yes, I am aware there are other ways
> to determine that the setegid call failed.  The problem is that the
> documentation tells me that the correct way to evaluate failure is to
> check errno after calls, and the call fails to initialize errno
> correctly.  Either the docs or the function are wrong.

Normal POSIX behaviour is for errno only to be set on error, never
cleared.  See errno(3): "[...] errno is never set to zero by any
library function."  I would be surprised if Perl changed this
behaviour.

Suggest that you explicitly initialise $! to 0.



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to