2
* See the file LICENSE for redistribution information.
4
* Copyright (c) 1999-2002
5
* Sleepycat Software. All rights reserved.
11
static const char revid[] = "$Id$";
17
* __os_get_errno_ret_zero --
18
* Return the value of errno, even if it's zero.
20
* PUBLIC: int __os_get_errno_ret_zero __P((void));
23
__os_get_errno_ret_zero()
25
/* This routine must be able to return the same value repeatedly. */
31
* Return the value of errno, or EAGAIN if errno is zero.
33
* PUBLIC: int __os_get_errno __P((void));
39
* This routine must be able to return the same value repeatedly.
41
* We've seen cases where system calls failed but errno was never set.
42
* This version of __os_get_errno() sets errno to EAGAIN if it's not
43
* already set, to work around that problem. For obvious reasons, we
44
* can only call this function if we know an error has occurred, that
45
* is, we can't test errno for a non-zero value after this call.
48
__os_set_errno(EAGAIN);
55
* Set the value of errno.
57
* PUBLIC: void __os_set_errno __P((int));
60
__os_set_errno(evalue)