Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

apr_errno.h

Go to the documentation of this file.
00001 /* ==================================================================== 00002 * The Apache Software License, Version 1.1 00003 * 00004 * Copyright (c) 2000-2003 The Apache Software Foundation. All rights 00005 * reserved. 00006 * 00007 * Redistribution and use in source and binary forms, with or without 00008 * modification, are permitted provided that the following conditions 00009 * are met: 00010 * 00011 * 1. Redistributions of source code must retain the above copyright 00012 * notice, this list of conditions and the following disclaimer. 00013 * 00014 * 2. Redistributions in binary form must reproduce the above copyright 00015 * notice, this list of conditions and the following disclaimer in 00016 * the documentation and/or other materials provided with the 00017 * distribution. 00018 * 00019 * 3. The end-user documentation included with the redistribution, 00020 * if any, must include the following acknowledgment: 00021 * "This product includes software developed by the 00022 * Apache Software Foundation (http://www.apache.org/)." 00023 * Alternately, this acknowledgment may appear in the software itself, 00024 * if and wherever such third-party acknowledgments normally appear. 00025 * 00026 * 4. The names "Apache" and "Apache Software Foundation" must 00027 * not be used to endorse or promote products derived from this 00028 * software without prior written permission. For written 00029 * permission, please contact apache@apache.org. 00030 * 00031 * 5. Products derived from this software may not be called "Apache", 00032 * nor may "Apache" appear in their name, without prior written 00033 * permission of the Apache Software Foundation. 00034 * 00035 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED 00036 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 00037 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00038 * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR 00039 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 00040 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 00041 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF 00042 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 00043 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 00044 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT 00045 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 00046 * SUCH DAMAGE. 00047 * ==================================================================== 00048 * 00049 * This software consists of voluntary contributions made by many 00050 * individuals on behalf of the Apache Software Foundation. For more 00051 * information on the Apache Software Foundation, please see 00052 * <http://www.apache.org/>. 00053 */ 00054 00055 #ifndef APR_ERRNO_H 00056 #define APR_ERRNO_H 00057 00063 #include "apr.h" 00064 00065 #if APR_HAVE_ERRNO_H 00066 #include <errno.h> 00067 #endif 00068 00069 #ifdef __cplusplus 00070 extern "C" { 00071 #endif /* __cplusplus */ 00072 00082 typedef int apr_status_t; 00083 00090 APR_DECLARE(char *) apr_strerror(apr_status_t statcode, char *buf, 00091 apr_size_t bufsize); 00092 00093 #if defined(DOXYGEN) 00102 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR) 00103 00113 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR) 00114 00150 #endif /* defined(DOXYGEN) */ 00151 00155 #define APR_OS_START_ERROR 20000 00161 #define APR_OS_ERRSPACE_SIZE 50000 00165 #define APR_OS_START_STATUS (APR_OS_START_ERROR + APR_OS_ERRSPACE_SIZE) 00173 #define APR_OS_START_USERERR (APR_OS_START_STATUS + APR_OS_ERRSPACE_SIZE) 00178 #define APR_OS_START_USEERR APR_OS_START_USERERR 00183 #define APR_OS_START_CANONERR (APR_OS_START_USERERR \ 00184 + (APR_OS_ERRSPACE_SIZE * 10)) 00189 #define APR_OS_START_EAIERR (APR_OS_START_CANONERR + APR_OS_ERRSPACE_SIZE) 00194 #define APR_OS_START_SYSERR (APR_OS_START_EAIERR + APR_OS_ERRSPACE_SIZE) 00195 00197 #define APR_SUCCESS 0 00198 00259 #define APR_ENOSTAT (APR_OS_START_ERROR + 1) 00261 #define APR_ENOPOOL (APR_OS_START_ERROR + 2) 00262 /* empty slot: +3 */ 00264 #define APR_EBADDATE (APR_OS_START_ERROR + 4) 00266 #define APR_EINVALSOCK (APR_OS_START_ERROR + 5) 00268 #define APR_ENOPROC (APR_OS_START_ERROR + 6) 00270 #define APR_ENOTIME (APR_OS_START_ERROR + 7) 00272 #define APR_ENODIR (APR_OS_START_ERROR + 8) 00274 #define APR_ENOLOCK (APR_OS_START_ERROR + 9) 00276 #define APR_ENOPOLL (APR_OS_START_ERROR + 10) 00278 #define APR_ENOSOCKET (APR_OS_START_ERROR + 11) 00280 #define APR_ENOTHREAD (APR_OS_START_ERROR + 12) 00282 #define APR_ENOTHDKEY (APR_OS_START_ERROR + 13) 00284 #define APR_EGENERAL (APR_OS_START_ERROR + 14) 00286 #define APR_ENOSHMAVAIL (APR_OS_START_ERROR + 15) 00288 #define APR_EBADIP (APR_OS_START_ERROR + 16) 00290 #define APR_EBADMASK (APR_OS_START_ERROR + 17) 00291 /* empty slot: +18 */ 00293 #define APR_EDSOOPEN (APR_OS_START_ERROR + 19) 00295 #define APR_EABSOLUTE (APR_OS_START_ERROR + 20) 00297 #define APR_ERELATIVE (APR_OS_START_ERROR + 21) 00299 #define APR_EINCOMPLETE (APR_OS_START_ERROR + 22) 00301 #define APR_EABOVEROOT (APR_OS_START_ERROR + 23) 00303 #define APR_EBADPATH (APR_OS_START_ERROR + 24) 00305 #define APR_EPATHWILD (APR_OS_START_ERROR + 25) 00307 #define APR_ESYMNOTFOUND (APR_OS_START_ERROR + 26) 00309 #define APR_EPROC_UNKNOWN (APR_OS_START_ERROR + 27) 00328 #define APR_STATUS_IS_ENOSTAT(s) ((s) == APR_ENOSTAT) 00334 #define APR_STATUS_IS_ENOPOOL(s) ((s) == APR_ENOPOOL) 00336 #define APR_STATUS_IS_EBADDATE(s) ((s) == APR_EBADDATE) 00338 #define APR_STATUS_IS_EINVALSOCK(s) ((s) == APR_EINVALSOCK) 00340 #define APR_STATUS_IS_ENOPROC(s) ((s) == APR_ENOPROC) 00342 #define APR_STATUS_IS_ENOTIME(s) ((s) == APR_ENOTIME) 00344 #define APR_STATUS_IS_ENODIR(s) ((s) == APR_ENODIR) 00346 #define APR_STATUS_IS_ENOLOCK(s) ((s) == APR_ENOLOCK) 00348 #define APR_STATUS_IS_ENOPOLL(s) ((s) == APR_ENOPOLL) 00350 #define APR_STATUS_IS_ENOSOCKET(s) ((s) == APR_ENOSOCKET) 00352 #define APR_STATUS_IS_ENOTHREAD(s) ((s) == APR_ENOTHREAD) 00354 #define APR_STATUS_IS_ENOTHDKEY(s) ((s) == APR_ENOTHDKEY) 00356 #define APR_STATUS_IS_EGENERAL(s) ((s) == APR_EGENERAL) 00358 #define APR_STATUS_IS_ENOSHMAVAIL(s) ((s) == APR_ENOSHMAVAIL) 00360 #define APR_STATUS_IS_EBADIP(s) ((s) == APR_EBADIP) 00362 #define APR_STATUS_IS_EBADMASK(s) ((s) == APR_EBADMASK) 00363 /* empty slot: +18 */ 00368 #if defined(WIN32) 00369 #define APR_STATUS_IS_EDSOOPEN(s) ((s) == APR_EDSOOPEN \ 00370 || APR_TO_OS_ERROR(s) == ERROR_MOD_NOT_FOUND) 00371 #else 00372 #define APR_STATUS_IS_EDSOOPEN(s) ((s) == APR_EDSOOPEN) 00373 #endif 00375 #define APR_STATUS_IS_EABSOLUTE(s) ((s) == APR_EABSOLUTE) 00377 #define APR_STATUS_IS_ERELATIVE(s) ((s) == APR_ERELATIVE) 00379 #define APR_STATUS_IS_EINCOMPLETE(s) ((s) == APR_EINCOMPLETE) 00381 #define APR_STATUS_IS_EABOVEROOT(s) ((s) == APR_EABOVEROOT) 00383 #define APR_STATUS_IS_EBADPATH(s) ((s) == APR_EBADPATH) 00385 #define APR_STATUS_IS_EPATHWILD(s) ((s) == APR_EPATHWILD) 00389 #if defined(WIN32) 00390 #define APR_STATUS_IS_ESYMNOTFOUND(s) ((s) == APR_ESYMNOTFOUND \ 00391 || APR_TO_OS_ERROR(s) == ERROR_PROC_NOT_FOUND) 00392 #else 00393 #define APR_STATUS_IS_ESYMNOTFOUND(s) ((s) == APR_ESYMNOTFOUND) 00394 #endif 00396 #define APR_STATUS_IS_EPROC_UNKNOWN(s) ((s) == APR_EPROC_UNKNOWN) 00397 00405 #define APR_INCHILD (APR_OS_START_STATUS + 1) 00407 #define APR_INPARENT (APR_OS_START_STATUS + 2) 00409 #define APR_DETACH (APR_OS_START_STATUS + 3) 00411 #define APR_NOTDETACH (APR_OS_START_STATUS + 4) 00413 #define APR_CHILD_DONE (APR_OS_START_STATUS + 5) 00415 #define APR_CHILD_NOTDONE (APR_OS_START_STATUS + 6) 00417 #define APR_TIMEUP (APR_OS_START_STATUS + 7) 00419 #define APR_INCOMPLETE (APR_OS_START_STATUS + 8) 00420 /* empty slot: +9 */ 00421 /* empty slot: +10 */ 00422 /* empty slot: +11 */ 00424 #define APR_BADCH (APR_OS_START_STATUS + 12) 00426 #define APR_BADARG (APR_OS_START_STATUS + 13) 00428 #define APR_EOF (APR_OS_START_STATUS + 14) 00430 #define APR_NOTFOUND (APR_OS_START_STATUS + 15) 00431 /* empty slot: +16 */ 00432 /* empty slot: +17 */ 00433 /* empty slot: +18 */ 00435 #define APR_ANONYMOUS (APR_OS_START_STATUS + 19) 00437 #define APR_FILEBASED (APR_OS_START_STATUS + 20) 00439 #define APR_KEYBASED (APR_OS_START_STATUS + 21) 00441 #define APR_EINIT (APR_OS_START_STATUS + 22) 00443 #define APR_ENOTIMPL (APR_OS_START_STATUS + 23) 00445 #define APR_EMISMATCH (APR_OS_START_STATUS + 24) 00447 #define APR_EBUSY (APR_OS_START_STATUS + 25) 00459 #define APR_STATUS_IS_INCHILD(s) ((s) == APR_INCHILD) 00466 #define APR_STATUS_IS_INPARENT(s) ((s) == APR_INPARENT) 00473 #define APR_STATUS_IS_DETACH(s) ((s) == APR_DETACH) 00480 #define APR_STATUS_IS_NOTDETACH(s) ((s) == APR_NOTDETACH) 00487 #define APR_STATUS_IS_CHILD_DONE(s) ((s) == APR_CHILD_DONE) 00494 #define APR_STATUS_IS_CHILD_NOTDONE(s) ((s) == APR_CHILD_NOTDONE) 00501 #define APR_STATUS_IS_TIMEUP(s) ((s) == APR_TIMEUP) 00509 #define APR_STATUS_IS_INCOMPLETE(s) ((s) == APR_INCOMPLETE) 00510 /* empty slot: +9 */ 00511 /* empty slot: +10 */ 00512 /* empty slot: +11 */ 00519 #define APR_STATUS_IS_BADCH(s) ((s) == APR_BADCH) 00527 #define APR_STATUS_IS_BADARG(s) ((s) == APR_BADARG) 00534 #define APR_STATUS_IS_EOF(s) ((s) == APR_EOF) 00541 #define APR_STATUS_IS_NOTFOUND(s) ((s) == APR_NOTFOUND) 00542 /* empty slot: +16 */ 00543 /* empty slot: +17 */ 00544 /* empty slot: +18 */ 00551 #define APR_STATUS_IS_ANONYMOUS(s) ((s) == APR_ANONYMOUS) 00558 #define APR_STATUS_IS_FILEBASED(s) ((s) == APR_FILEBASED) 00565 #define APR_STATUS_IS_KEYBASED(s) ((s) == APR_KEYBASED) 00573 #define APR_STATUS_IS_EINIT(s) ((s) == APR_EINIT) 00582 #define APR_STATUS_IS_ENOTIMPL(s) ((s) == APR_ENOTIMPL) 00589 #define APR_STATUS_IS_EMISMATCH(s) ((s) == APR_EMISMATCH) 00595 #define APR_STATUS_IS_EBUSY(s) ((s) == APR_EBUSY) 00596 00603 /* APR CANONICAL ERROR VALUES */ 00605 #ifdef EACCES 00606 #define APR_EACCES EACCES 00607 #else 00608 #define APR_EACCES (APR_OS_START_CANONERR + 1) 00609 #endif 00610 00612 #ifdef EEXIST 00613 #define APR_EEXIST EEXIST 00614 #else 00615 #define APR_EEXIST (APR_OS_START_CANONERR + 2) 00616 #endif 00617 00619 #ifdef ENAMETOOLONG 00620 #define APR_ENAMETOOLONG ENAMETOOLONG 00621 #else 00622 #define APR_ENAMETOOLONG (APR_OS_START_CANONERR + 3) 00623 #endif 00624 00626 #ifdef ENOENT 00627 #define APR_ENOENT ENOENT 00628 #else 00629 #define APR_ENOENT (APR_OS_START_CANONERR + 4) 00630 #endif 00631 00633 #ifdef ENOTDIR 00634 #define APR_ENOTDIR ENOTDIR 00635 #else 00636 #define APR_ENOTDIR (APR_OS_START_CANONERR + 5) 00637 #endif 00638 00640 #ifdef ENOSPC 00641 #define APR_ENOSPC ENOSPC 00642 #else 00643 #define APR_ENOSPC (APR_OS_START_CANONERR + 6) 00644 #endif 00645 00647 #ifdef ENOMEM 00648 #define APR_ENOMEM ENOMEM 00649 #else 00650 #define APR_ENOMEM (APR_OS_START_CANONERR + 7) 00651 #endif 00652 00654 #ifdef EMFILE 00655 #define APR_EMFILE EMFILE 00656 #else 00657 #define APR_EMFILE (APR_OS_START_CANONERR + 8) 00658 #endif 00659 00661 #ifdef ENFILE 00662 #define APR_ENFILE ENFILE 00663 #else 00664 #define APR_ENFILE (APR_OS_START_CANONERR + 9) 00665 #endif 00666 00668 #ifdef EBADF 00669 #define APR_EBADF EBADF 00670 #else 00671 #define APR_EBADF (APR_OS_START_CANONERR + 10) 00672 #endif 00673 00675 #ifdef EINVAL 00676 #define APR_EINVAL EINVAL 00677 #else 00678 #define APR_EINVAL (APR_OS_START_CANONERR + 11) 00679 #endif 00680 00682 #ifdef ESPIPE 00683 #define APR_ESPIPE ESPIPE 00684 #else 00685 #define APR_ESPIPE (APR_OS_START_CANONERR + 12) 00686 #endif 00687 00692 #ifdef EAGAIN 00693 #define APR_EAGAIN EAGAIN 00694 #elif defined(EWOULDBLOCK) 00695 #define APR_EAGAIN EWOULDBLOCK 00696 #else 00697 #define APR_EAGAIN (APR_OS_START_CANONERR + 13) 00698 #endif 00699 00701 #ifdef EINTR 00702 #define APR_EINTR EINTR 00703 #else 00704 #define APR_EINTR (APR_OS_START_CANONERR + 14) 00705 #endif 00706 00708 #ifdef ENOTSOCK 00709 #define APR_ENOTSOCK ENOTSOCK 00710 #else 00711 #define APR_ENOTSOCK (APR_OS_START_CANONERR + 15) 00712 #endif 00713 00715 #ifdef ECONNREFUSED 00716 #define APR_ECONNREFUSED ECONNREFUSED 00717 #else 00718 #define APR_ECONNREFUSED (APR_OS_START_CANONERR + 16) 00719 #endif 00720 00722 #ifdef EINPROGRESS 00723 #define APR_EINPROGRESS EINPROGRESS 00724 #else 00725 #define APR_EINPROGRESS (APR_OS_START_CANONERR + 17) 00726 #endif 00727 00733 #ifdef ECONNABORTED 00734 #define APR_ECONNABORTED ECONNABORTED 00735 #else 00736 #define APR_ECONNABORTED (APR_OS_START_CANONERR + 18) 00737 #endif 00738 00740 #ifdef ECONNRESET 00741 #define APR_ECONNRESET ECONNRESET 00742 #else 00743 #define APR_ECONNRESET (APR_OS_START_CANONERR + 19) 00744 #endif 00745 00747 #ifdef ETIMEDOUT 00748 #define APR_ETIMEDOUT ETIMEDOUT 00749 #else 00750 #define APR_ETIMEDOUT (APR_OS_START_CANONERR + 20) 00751 #endif 00752 00754 #ifdef EHOSTUNREACH 00755 #define APR_EHOSTUNREACH EHOSTUNREACH 00756 #else 00757 #define APR_EHOSTUNREACH (APR_OS_START_CANONERR + 21) 00758 #endif 00759 00761 #ifdef ENETUNREACH 00762 #define APR_ENETUNREACH ENETUNREACH 00763 #else 00764 #define APR_ENETUNREACH (APR_OS_START_CANONERR + 22) 00765 #endif 00766 00768 #ifdef EFTYPE 00769 #define APR_EFTYPE EFTYPE 00770 #else 00771 #define APR_EFTYPE (APR_OS_START_CANONERR + 23) 00772 #endif 00773 00775 #ifdef EPIPE 00776 #define APR_EPIPE EPIPE 00777 #else 00778 #define APR_EPIPE (APR_OS_START_CANONERR + 24) 00779 #endif 00780 00782 #ifdef EXDEV 00783 #define APR_EXDEV EXDEV 00784 #else 00785 #define APR_EXDEV (APR_OS_START_CANONERR + 25) 00786 #endif 00787 00789 #ifdef ENOTEMPTY 00790 #define APR_ENOTEMPTY ENOTEMPTY 00791 #else 00792 #define APR_ENOTEMPTY (APR_OS_START_CANONERR + 26) 00793 #endif 00794 00797 #if defined(OS2) && !defined(DOXYGEN) 00798 00799 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR) 00800 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR) 00801 00802 #define INCL_DOSERRORS 00803 #define INCL_DOS 00804 00805 /* Leave these undefined. 00806 * OS2 doesn't rely on the errno concept. 00807 * The API calls always return a result codes which 00808 * should be filtered through APR_FROM_OS_ERROR(). 00809 * 00810 * #define apr_get_os_error() (APR_FROM_OS_ERROR(GetLastError())) 00811 * #define apr_set_os_error(e) (SetLastError(APR_TO_OS_ERROR(e))) 00812 */ 00813 00814 /* A special case, only socket calls require this; 00815 */ 00816 #define apr_get_netos_error() (APR_FROM_OS_ERROR(errno)) 00817 #define apr_set_netos_error(e) (errno = APR_TO_OS_ERROR(e)) 00818 00819 /* And this needs to be greped away for good: 00820 */ 00821 #define APR_OS2_STATUS(e) (APR_FROM_OS_ERROR(e)) 00822 00823 #define APR_STATUS_IS_SUCCESS(s) ((s) == APR_SUCCESS \ 00824 || (s) == APR_OS_START_SYSERR + NO_ERROR) 00825 00826 /* These can't sit in a private header, so in spite of the extra size, 00827 * they need to be made available here. 00828 */ 00829 #define SOCBASEERR 10000 00830 #define SOCEPERM (SOCBASEERR+1) /* Not owner */ 00831 #define SOCESRCH (SOCBASEERR+3) /* No such process */ 00832 #define SOCEINTR (SOCBASEERR+4) /* Interrupted system call */ 00833 #define SOCENXIO (SOCBASEERR+6) /* No such device or address */ 00834 #define SOCEBADF (SOCBASEERR+9) /* Bad file number */ 00835 #define SOCEACCES (SOCBASEERR+13) /* Permission denied */ 00836 #define SOCEFAULT (SOCBASEERR+14) /* Bad address */ 00837 #define SOCEINVAL (SOCBASEERR+22) /* Invalid argument */ 00838 #define SOCEMFILE (SOCBASEERR+24) /* Too many open files */ 00839 #define SOCEPIPE (SOCBASEERR+32) /* Broken pipe */ 00840 #define SOCEOS2ERR (SOCBASEERR+100) /* OS/2 Error */ 00841 #define SOCEWOULDBLOCK (SOCBASEERR+35) /* Operation would block */ 00842 #define SOCEINPROGRESS (SOCBASEERR+36) /* Operation now in progress */ 00843 #define SOCEALREADY (SOCBASEERR+37) /* Operation already in progress */ 00844 #define SOCENOTSOCK (SOCBASEERR+38) /* Socket operation on non-socket */ 00845 #define SOCEDESTADDRREQ (SOCBASEERR+39) /* Destination address required */ 00846 #define SOCEMSGSIZE (SOCBASEERR+40) /* Message too long */ 00847 #define SOCEPROTOTYPE (SOCBASEERR+41) /* Protocol wrong type for socket */ 00848 #define SOCENOPROTOOPT (SOCBASEERR+42) /* Protocol not available */ 00849 #define SOCEPROTONOSUPPORT (SOCBASEERR+43) /* Protocol not supported */ 00850 #define SOCESOCKTNOSUPPORT (SOCBASEERR+44) /* Socket type not supported */ 00851 #define SOCEOPNOTSUPP (SOCBASEERR+45) /* Operation not supported on socket */ 00852 #define SOCEPFNOSUPPORT (SOCBASEERR+46) /* Protocol family not supported */ 00853 #define SOCEAFNOSUPPORT (SOCBASEERR+47) /* Address family not supported by protocol family */ 00854 #define SOCEADDRINUSE (SOCBASEERR+48) /* Address already in use */ 00855 #define SOCEADDRNOTAVAIL (SOCBASEERR+49) /* Can't assign requested address */ 00856 #define SOCENETDOWN (SOCBASEERR+50) /* Network is down */ 00857 #define SOCENETUNREACH (SOCBASEERR+51) /* Network is unreachable */ 00858 #define SOCENETRESET (SOCBASEERR+52) /* Network dropped connection on reset */ 00859 #define SOCECONNABORTED (SOCBASEERR+53) /* Software caused connection abort */ 00860 #define SOCECONNRESET (SOCBASEERR+54) /* Connection reset by peer */ 00861 #define SOCENOBUFS (SOCBASEERR+55) /* No buffer space available */ 00862 #define SOCEISCONN (SOCBASEERR+56) /* Socket is already connected */ 00863 #define SOCENOTCONN (SOCBASEERR+57) /* Socket is not connected */ 00864 #define SOCESHUTDOWN (SOCBASEERR+58) /* Can't send after socket shutdown */ 00865 #define SOCETOOMANYREFS (SOCBASEERR+59) /* Too many references: can't splice */ 00866 #define SOCETIMEDOUT (SOCBASEERR+60) /* Connection timed out */ 00867 #define SOCECONNREFUSED (SOCBASEERR+61) /* Connection refused */ 00868 #define SOCELOOP (SOCBASEERR+62) /* Too many levels of symbolic links */ 00869 #define SOCENAMETOOLONG (SOCBASEERR+63) /* File name too long */ 00870 #define SOCEHOSTDOWN (SOCBASEERR+64) /* Host is down */ 00871 #define SOCEHOSTUNREACH (SOCBASEERR+65) /* No route to host */ 00872 #define SOCENOTEMPTY (SOCBASEERR+66) /* Directory not empty */ 00873 00874 /* APR CANONICAL ERROR TESTS */ 00875 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES \ 00876 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED \ 00877 || (s) == APR_OS_START_SYSERR + ERROR_SHARING_VIOLATION) 00878 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST \ 00879 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED \ 00880 || (s) == APR_OS_START_SYSERR + ERROR_FILE_EXISTS \ 00881 || (s) == APR_OS_START_SYSERR + ERROR_ALREADY_EXISTS \ 00882 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED) 00883 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG \ 00884 || (s) == APR_OS_START_SYSERR + ERROR_FILENAME_EXCED_RANGE \ 00885 || (s) == APR_OS_START_SYSERR + SOCENAMETOOLONG) 00886 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT \ 00887 || (s) == APR_OS_START_SYSERR + ERROR_FILE_NOT_FOUND \ 00888 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \ 00889 || (s) == APR_OS_START_SYSERR + ERROR_NO_MORE_FILES \ 00890 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED) 00891 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR) 00892 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC \ 00893 || (s) == APR_OS_START_SYSERR + ERROR_DISK_FULL) 00894 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM) 00895 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE \ 00896 || (s) == APR_OS_START_SYSERR + ERROR_TOO_MANY_OPEN_FILES) 00897 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE) 00898 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF \ 00899 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE) 00900 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL \ 00901 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_PARAMETER \ 00902 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_FUNCTION) 00903 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE \ 00904 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK) 00905 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \ 00906 || (s) == APR_OS_START_SYSERR + ERROR_NO_DATA \ 00907 || (s) == APR_OS_START_SYSERR + SOCEWOULDBLOCK \ 00908 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION) 00909 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \ 00910 || (s) == APR_OS_START_SYSERR + SOCEINTR) 00911 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \ 00912 || (s) == APR_OS_START_SYSERR + SOCENOTSOCK) 00913 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \ 00914 || (s) == APR_OS_START_SYSERR + SOCECONNREFUSED) 00915 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \ 00916 || (s) == APR_OS_START_SYSERR + SOCEINPROGRESS) 00917 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \ 00918 || (s) == APR_OS_START_SYSERR + SOCECONNABORTED) 00919 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \ 00920 || (s) == APR_OS_START_SYSERR + SOCECONNRESET) 00921 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \ 00922 || (s) == APR_OS_START_SYSERR + SOCETIMEDOUT) 00923 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \ 00924 || (s) == APR_OS_START_SYSERR + SOCEHOSTUNREACH) 00925 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \ 00926 || (s) == APR_OS_START_SYSERR + SOCENETUNREACH) 00927 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE) 00928 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE \ 00929 || (s) == APR_OS_START_SYSERR + ERROR_BROKEN_PIPE \ 00930 || (s) == APR_OS_START_SYSERR + SOCEPIPE) 00931 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV \ 00932 || (s) == APR_OS_START_SYSERR + ERROR_NOT_SAME_DEVICE) 00933 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY \ 00934 || (s) == APR_OS_START_SYSERR + ERROR_DIR_NOT_EMPTY \ 00935 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED) 00936 00937 /* 00938 Sorry, too tired to wrap this up for OS2... feel free to 00939 fit the following into their best matches. 00940 00941 { ERROR_NO_SIGNAL_SENT, ESRCH }, 00942 { SOCEALREADY, EALREADY }, 00943 { SOCEDESTADDRREQ, EDESTADDRREQ }, 00944 { SOCEMSGSIZE, EMSGSIZE }, 00945 { SOCEPROTOTYPE, EPROTOTYPE }, 00946 { SOCENOPROTOOPT, ENOPROTOOPT }, 00947 { SOCEPROTONOSUPPORT, EPROTONOSUPPORT }, 00948 { SOCESOCKTNOSUPPORT, ESOCKTNOSUPPORT }, 00949 { SOCEOPNOTSUPP, EOPNOTSUPP }, 00950 { SOCEPFNOSUPPORT, EPFNOSUPPORT }, 00951 { SOCEAFNOSUPPORT, EAFNOSUPPORT }, 00952 { SOCEADDRINUSE, EADDRINUSE }, 00953 { SOCEADDRNOTAVAIL, EADDRNOTAVAIL }, 00954 { SOCENETDOWN, ENETDOWN }, 00955 { SOCENETRESET, ENETRESET }, 00956 { SOCENOBUFS, ENOBUFS }, 00957 { SOCEISCONN, EISCONN }, 00958 { SOCENOTCONN, ENOTCONN }, 00959 { SOCESHUTDOWN, ESHUTDOWN }, 00960 { SOCETOOMANYREFS, ETOOMANYREFS }, 00961 { SOCELOOP, ELOOP }, 00962 { SOCEHOSTDOWN, EHOSTDOWN }, 00963 { SOCENOTEMPTY, ENOTEMPTY }, 00964 { SOCEPIPE, EPIPE } 00965 */ 00966 00967 #elif defined(WIN32) && !defined(DOXYGEN) /* !defined(OS2) */ 00968 00969 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR) 00970 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR) 00971 00972 #define apr_get_os_error() (APR_FROM_OS_ERROR(GetLastError())) 00973 #define apr_set_os_error(e) (SetLastError(APR_TO_OS_ERROR(e))) 00974 00975 /* A special case, only socket calls require this: 00976 */ 00977 #define apr_get_netos_error() (APR_FROM_OS_ERROR(WSAGetLastError())) 00978 #define apr_set_netos_error(e) (WSASetLastError(APR_TO_OS_ERROR(e))) 00979 00980 #define APR_STATUS_IS_SUCCESS(s) ((s) == APR_SUCCESS \ 00981 || (s) == APR_OS_START_SYSERR + ERROR_SUCCESS) 00982 00983 /* APR CANONICAL ERROR TESTS */ 00984 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES \ 00985 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED \ 00986 || (s) == APR_OS_START_SYSERR + ERROR_CANNOT_MAKE \ 00987 || (s) == APR_OS_START_SYSERR + ERROR_CURRENT_DIRECTORY \ 00988 || (s) == APR_OS_START_SYSERR + ERROR_DRIVE_LOCKED \ 00989 || (s) == APR_OS_START_SYSERR + ERROR_FAIL_I24 \ 00990 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION \ 00991 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_FAILED \ 00992 || (s) == APR_OS_START_SYSERR + ERROR_NOT_LOCKED \ 00993 || (s) == APR_OS_START_SYSERR + ERROR_NETWORK_ACCESS_DENIED \ 00994 || (s) == APR_OS_START_SYSERR + ERROR_SHARING_VIOLATION) 00995 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST \ 00996 || (s) == APR_OS_START_SYSERR + ERROR_FILE_EXISTS \ 00997 || (s) == APR_OS_START_SYSERR + ERROR_ALREADY_EXISTS) 00998 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG \ 00999 || (s) == APR_OS_START_SYSERR + ERROR_FILENAME_EXCED_RANGE \ 01000 || (s) == APR_OS_START_SYSERR + WSAENAMETOOLONG) 01001 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT \ 01002 || (s) == APR_OS_START_SYSERR + ERROR_FILE_NOT_FOUND \ 01003 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \ 01004 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED \ 01005 || (s) == APR_OS_START_SYSERR + ERROR_NO_MORE_FILES) 01006 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR \ 01007 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \ 01008 || (s) == APR_OS_START_SYSERR + ERROR_BAD_NETPATH \ 01009 || (s) == APR_OS_START_SYSERR + ERROR_BAD_NET_NAME \ 01010 || (s) == APR_OS_START_SYSERR + ERROR_BAD_PATHNAME \ 01011 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DRIVE) 01012 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC \ 01013 || (s) == APR_OS_START_SYSERR + ERROR_DISK_FULL) 01014 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM \ 01015 || (s) == APR_OS_START_SYSERR + ERROR_ARENA_TRASHED \ 01016 || (s) == APR_OS_START_SYSERR + ERROR_NOT_ENOUGH_MEMORY \ 01017 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_BLOCK \ 01018 || (s) == APR_OS_START_SYSERR + ERROR_NOT_ENOUGH_QUOTA \ 01019 || (s) == APR_OS_START_SYSERR + ERROR_OUTOFMEMORY) 01020 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE \ 01021 || (s) == APR_OS_START_SYSERR + ERROR_TOO_MANY_OPEN_FILES) 01022 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE) 01023 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF \ 01024 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE \ 01025 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_TARGET_HANDLE) 01026 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL \ 01027 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_ACCESS \ 01028 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DATA \ 01029 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_FUNCTION \ 01030 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE \ 01031 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_PARAMETER \ 01032 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK) 01033 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE \ 01034 || (s) == APR_OS_START_SYSERR + ERROR_SEEK_ON_DEVICE \ 01035 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK) 01036 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \ 01037 || (s) == APR_OS_START_SYSERR + ERROR_NO_DATA \ 01038 || (s) == APR_OS_START_SYSERR + ERROR_NO_PROC_SLOTS \ 01039 || (s) == APR_OS_START_SYSERR + ERROR_NESTING_NOT_ALLOWED \ 01040 || (s) == APR_OS_START_SYSERR + ERROR_MAX_THRDS_REACHED \ 01041 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION \ 01042 || (s) == APR_OS_START_SYSERR + WSAEWOULDBLOCK) 01043 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \ 01044 || (s) == APR_OS_START_SYSERR + WSAEINTR) 01045 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \ 01046 || (s) == APR_OS_START_SYSERR + WSAENOTSOCK) 01047 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \ 01048 || (s) == APR_OS_START_SYSERR + WSAECONNREFUSED) 01049 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \ 01050 || (s) == APR_OS_START_SYSERR + WSAEINPROGRESS) 01051 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \ 01052 || (s) == APR_OS_START_SYSERR + WSAECONNABORTED) 01053 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \ 01054 || (s) == APR_OS_START_SYSERR + ERROR_NETNAME_DELETED \ 01055 || (s) == APR_OS_START_SYSERR + WSAECONNRESET) 01056 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \ 01057 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \ 01058 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT) 01059 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \ 01060 || (s) == APR_OS_START_SYSERR + WSAEHOSTUNREACH) 01061 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \ 01062 || (s) == APR_OS_START_SYSERR + WSAENETUNREACH) 01063 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE \ 01064 || (s) == APR_OS_START_SYSERR + ERROR_EXE_MACHINE_TYPE_MISMATCH \ 01065 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DLL \ 01066 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_MODULETYPE \ 01067 || (s) == APR_OS_START_SYSERR + ERROR_BAD_EXE_FORMAT \ 01068 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_EXE_SIGNATURE \ 01069 || (s) == APR_OS_START_SYSERR + ERROR_FILE_CORRUPT \ 01070 || (s) == APR_OS_START_SYSERR + ERROR_BAD_FORMAT) 01071 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE \ 01072 || (s) == APR_OS_START_SYSERR + ERROR_BROKEN_PIPE) 01073 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV \ 01074 || (s) == APR_OS_START_SYSERR + ERROR_NOT_SAME_DEVICE) 01075 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY \ 01076 || (s) == APR_OS_START_SYSERR + ERROR_DIR_NOT_EMPTY) 01077 01078 #elif defined(NETWARE) && !defined(DOXYGEN) /* !defined(OS2) && !defined(WIN32) */ 01079 01080 #define APR_FROM_OS_ERROR(e) (e) 01081 #define APR_TO_OS_ERROR(e) (e) 01082 01083 #define apr_get_os_error() (errno) 01084 #define apr_set_os_error(e) (errno = (e)) 01085 01086 #define apr_get_netos_error() (WSAGetLastError()+APR_OS_START_SYSERR) 01087 #define apr_set_netos_error(e) (WSASetLastError((e)-APR_OS_START_SYSERR)) 01088 01089 #define APR_STATUS_IS_SUCCESS(s) ((s) == APR_SUCCESS) 01090 01091 /* APR CANONICAL ERROR TESTS */ 01092 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES) 01093 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST) 01094 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG) 01095 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT) 01096 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR) 01097 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC) 01098 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM) 01099 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE) 01100 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE) 01101 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF) 01102 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL) 01103 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE) 01104 01105 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \ 01106 || (s) == EWOULDBLOCK \ 01107 || (s) == APR_OS_START_SYSERR + WSAEWOULDBLOCK) 01108 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \ 01109 || (s) == APR_OS_START_SYSERR + WSAEINTR) 01110 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \ 01111 || (s) == APR_OS_START_SYSERR + WSAENOTSOCK) 01112 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \ 01113 || (s) == APR_OS_START_SYSERR + WSAECONNREFUSED) 01114 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \ 01115 || (s) == APR_OS_START_SYSERR + WSAEINPROGRESS) 01116 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \ 01117 || (s) == APR_OS_START_SYSERR + WSAECONNABORTED) 01118 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \ 01119 || (s) == APR_OS_START_SYSERR + WSAECONNRESET) 01120 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \ 01121 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \ 01122 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT) 01123 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \ 01124 || (s) == APR_OS_START_SYSERR + WSAEHOSTUNREACH) 01125 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \ 01126 || (s) == APR_OS_START_SYSERR + WSAENETUNREACH) 01127 #define APR_STATUS_IS_ENETDOWN(s) ((s) == APR_OS_START_SYSERR + WSAENETDOWN) 01128 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE) 01129 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE) 01130 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV) 01131 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY) 01132 01133 #else /* !defined(NETWARE) && !defined(OS2) && !defined(WIN32) */ 01134 01135 /* 01136 * os error codes are clib error codes 01137 */ 01138 #define APR_FROM_OS_ERROR(e) (e) 01139 #define APR_TO_OS_ERROR(e) (e) 01140 01141 #define apr_get_os_error() (errno) 01142 #define apr_set_os_error(e) (errno = (e)) 01143 01144 /* A special case, only socket calls require this: 01145 */ 01146 #define apr_get_netos_error() (errno) 01147 #define apr_set_netos_error(e) (errno = (e)) 01155 #define APR_STATUS_IS_SUCCESS(s) ((s) == APR_SUCCESS) 01156 01158 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES) 01160 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST) 01162 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG) 01164 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT) 01166 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR) 01168 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC) 01170 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM) 01172 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE) 01174 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE) 01176 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF) 01178 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL) 01180 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE) 01181 01183 #if !defined(EWOULDBLOCK) || !defined(EAGAIN) 01184 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN) 01185 #elif (EWOULDBLOCK == EAGAIN) 01186 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN) 01187 #else 01188 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \ 01189 || (s) == EWOULDBLOCK) 01190 #endif 01191 01193 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR) 01195 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK) 01197 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED) 01199 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS) 01200 01212 #ifdef EPROTO 01213 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \ 01214 || (s) == EPROTO) 01215 #else 01216 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED) 01217 #endif 01218 01220 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET) 01222 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT) 01224 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH) 01226 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH) 01228 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE) 01230 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE) 01232 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV) 01234 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY || \ 01235 (s) == APR_EEXIST) 01238 #endif /* !defined(NETWARE) && !defined(OS2) && !defined(WIN32) */ 01239 01242 #ifdef __cplusplus 01243 } 01244 #endif 01245 01246 #endif /* ! APR_ERRNO_H */

Generated on Wed Sep 1 05:16:36 2004 for Apache Portable Runtime by doxygen 1.3.8