00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef APR_ERRNO_H
00018 #define APR_ERRNO_H
00019
00020
00021
00022
00023
00024
00025 #include "apr.h"
00026
00027 #if APR_HAVE_ERRNO_H
00028 #include <errno.h>
00029 #endif
00030
00031 #ifdef __cplusplus
00032 extern "C" {
00033 #endif
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044 typedef int apr_status_t;
00045
00046
00047
00048
00049
00050
00051
00052 APR_DECLARE(char *) apr_strerror(apr_status_t statcode, char *buf,
00053 apr_size_t bufsize);
00054
00055 #if defined(DOXYGEN)
00056
00057
00058
00059
00060
00061
00062
00063
00064 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR)
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR)
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112 #endif
00113
00114
00115
00116
00117 #define APR_OS_START_ERROR 20000
00118
00119
00120
00121
00122
00123 #define APR_OS_ERRSPACE_SIZE 50000
00124
00125
00126
00127
00128
00129
00130
00131
00132 #define APR_UTIL_ERRSPACE_SIZE 20000
00133
00134
00135
00136 #define APR_OS_START_STATUS (APR_OS_START_ERROR + APR_OS_ERRSPACE_SIZE)
00137
00138
00139
00140
00141 #define APR_UTIL_START_STATUS (APR_OS_START_STATUS + \
00142 (APR_OS_ERRSPACE_SIZE - APR_UTIL_ERRSPACE_SIZE))
00143
00144
00145
00146
00147
00148
00149
00150
00151
00152
00153
00154
00155
00156
00157
00158
00159
00160
00161
00162 #define APR_OS_START_USERERR (APR_OS_START_STATUS + APR_OS_ERRSPACE_SIZE)
00163
00164
00165
00166
00167 #define APR_OS_START_USEERR APR_OS_START_USERERR
00168
00169
00170
00171
00172 #define APR_OS_START_CANONERR (APR_OS_START_USERERR \
00173 + (APR_OS_ERRSPACE_SIZE * 10))
00174
00175
00176
00177
00178 #define APR_OS_START_EAIERR (APR_OS_START_CANONERR + APR_OS_ERRSPACE_SIZE)
00179
00180
00181
00182
00183 #define APR_OS_START_SYSERR (APR_OS_START_EAIERR + APR_OS_ERRSPACE_SIZE)
00184
00185
00186
00187
00188
00189
00190
00191
00192
00193
00194
00195
00196
00197
00198
00199
00200
00201
00202
00203
00204
00205
00206
00207
00208
00209
00210
00211
00212
00213
00214
00215
00216
00217
00218
00219
00220
00221
00222
00223 #define APR_SUCCESS 0
00224
00225
00226
00227
00228
00229
00230
00231
00232
00233
00234
00235
00236
00237
00238
00239
00240
00241
00242
00243
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00254
00255
00256
00257
00258
00259
00260
00261
00262
00263
00264
00265
00266
00267
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283
00284
00285
00286 #define APR_ENOSTAT (APR_OS_START_ERROR + 1)
00287
00288 #define APR_ENOPOOL (APR_OS_START_ERROR + 2)
00289
00290
00291 #define APR_EBADDATE (APR_OS_START_ERROR + 4)
00292
00293 #define APR_EINVALSOCK (APR_OS_START_ERROR + 5)
00294
00295 #define APR_ENOPROC (APR_OS_START_ERROR + 6)
00296
00297 #define APR_ENOTIME (APR_OS_START_ERROR + 7)
00298
00299 #define APR_ENODIR (APR_OS_START_ERROR + 8)
00300
00301 #define APR_ENOLOCK (APR_OS_START_ERROR + 9)
00302
00303 #define APR_ENOPOLL (APR_OS_START_ERROR + 10)
00304
00305 #define APR_ENOSOCKET (APR_OS_START_ERROR + 11)
00306
00307 #define APR_ENOTHREAD (APR_OS_START_ERROR + 12)
00308
00309 #define APR_ENOTHDKEY (APR_OS_START_ERROR + 13)
00310
00311 #define APR_EGENERAL (APR_OS_START_ERROR + 14)
00312
00313 #define APR_ENOSHMAVAIL (APR_OS_START_ERROR + 15)
00314
00315 #define APR_EBADIP (APR_OS_START_ERROR + 16)
00316
00317 #define APR_EBADMASK (APR_OS_START_ERROR + 17)
00318
00319
00320 #define APR_EDSOOPEN (APR_OS_START_ERROR + 19)
00321
00322 #define APR_EABSOLUTE (APR_OS_START_ERROR + 20)
00323
00324 #define APR_ERELATIVE (APR_OS_START_ERROR + 21)
00325
00326 #define APR_EINCOMPLETE (APR_OS_START_ERROR + 22)
00327
00328 #define APR_EABOVEROOT (APR_OS_START_ERROR + 23)
00329
00330 #define APR_EBADPATH (APR_OS_START_ERROR + 24)
00331
00332 #define APR_EPATHWILD (APR_OS_START_ERROR + 25)
00333
00334 #define APR_ESYMNOTFOUND (APR_OS_START_ERROR + 26)
00335
00336 #define APR_EPROC_UNKNOWN (APR_OS_START_ERROR + 27)
00337
00338 #define APR_ENOTENOUGHENTROPY (APR_OS_START_ERROR + 28)
00339
00340
00341
00342
00343
00344
00345
00346
00347
00348
00349
00350
00351
00352
00353
00354
00355
00356
00357 #define APR_STATUS_IS_ENOSTAT(s) ((s) == APR_ENOSTAT)
00358
00359
00360
00361
00362
00363 #define APR_STATUS_IS_ENOPOOL(s) ((s) == APR_ENOPOOL)
00364
00365 #define APR_STATUS_IS_EBADDATE(s) ((s) == APR_EBADDATE)
00366
00367 #define APR_STATUS_IS_EINVALSOCK(s) ((s) == APR_EINVALSOCK)
00368
00369 #define APR_STATUS_IS_ENOPROC(s) ((s) == APR_ENOPROC)
00370
00371 #define APR_STATUS_IS_ENOTIME(s) ((s) == APR_ENOTIME)
00372
00373 #define APR_STATUS_IS_ENODIR(s) ((s) == APR_ENODIR)
00374
00375 #define APR_STATUS_IS_ENOLOCK(s) ((s) == APR_ENOLOCK)
00376
00377 #define APR_STATUS_IS_ENOPOLL(s) ((s) == APR_ENOPOLL)
00378
00379 #define APR_STATUS_IS_ENOSOCKET(s) ((s) == APR_ENOSOCKET)
00380
00381 #define APR_STATUS_IS_ENOTHREAD(s) ((s) == APR_ENOTHREAD)
00382
00383 #define APR_STATUS_IS_ENOTHDKEY(s) ((s) == APR_ENOTHDKEY)
00384
00385 #define APR_STATUS_IS_EGENERAL(s) ((s) == APR_EGENERAL)
00386
00387 #define APR_STATUS_IS_ENOSHMAVAIL(s) ((s) == APR_ENOSHMAVAIL)
00388
00389 #define APR_STATUS_IS_EBADIP(s) ((s) == APR_EBADIP)
00390
00391 #define APR_STATUS_IS_EBADMASK(s) ((s) == APR_EBADMASK)
00392
00393
00394
00395
00396
00397 #if defined(WIN32)
00398 #define APR_STATUS_IS_EDSOOPEN(s) ((s) == APR_EDSOOPEN \
00399 || APR_TO_OS_ERROR(s) == ERROR_MOD_NOT_FOUND)
00400 #else
00401 #define APR_STATUS_IS_EDSOOPEN(s) ((s) == APR_EDSOOPEN)
00402 #endif
00403
00404 #define APR_STATUS_IS_EABSOLUTE(s) ((s) == APR_EABSOLUTE)
00405
00406 #define APR_STATUS_IS_ERELATIVE(s) ((s) == APR_ERELATIVE)
00407
00408 #define APR_STATUS_IS_EINCOMPLETE(s) ((s) == APR_EINCOMPLETE)
00409
00410 #define APR_STATUS_IS_EABOVEROOT(s) ((s) == APR_EABOVEROOT)
00411
00412 #define APR_STATUS_IS_EBADPATH(s) ((s) == APR_EBADPATH)
00413
00414 #define APR_STATUS_IS_EPATHWILD(s) ((s) == APR_EPATHWILD)
00415
00416
00417
00418 #if defined(WIN32)
00419 #define APR_STATUS_IS_ESYMNOTFOUND(s) ((s) == APR_ESYMNOTFOUND \
00420 || APR_TO_OS_ERROR(s) == ERROR_PROC_NOT_FOUND)
00421 #else
00422 #define APR_STATUS_IS_ESYMNOTFOUND(s) ((s) == APR_ESYMNOTFOUND)
00423 #endif
00424
00425 #define APR_STATUS_IS_EPROC_UNKNOWN(s) ((s) == APR_EPROC_UNKNOWN)
00426
00427 #define APR_STATUS_IS_ENOTENOUGHENTROPY(s) ((s) == APR_ENOTENOUGHENTROPY)
00428
00429
00430
00431
00432
00433
00434
00435
00436 #define APR_INCHILD (APR_OS_START_STATUS + 1)
00437
00438 #define APR_INPARENT (APR_OS_START_STATUS + 2)
00439
00440 #define APR_DETACH (APR_OS_START_STATUS + 3)
00441
00442 #define APR_NOTDETACH (APR_OS_START_STATUS + 4)
00443
00444 #define APR_CHILD_DONE (APR_OS_START_STATUS + 5)
00445
00446 #define APR_CHILD_NOTDONE (APR_OS_START_STATUS + 6)
00447
00448 #define APR_TIMEUP (APR_OS_START_STATUS + 7)
00449
00450 #define APR_INCOMPLETE (APR_OS_START_STATUS + 8)
00451
00452
00453
00454
00455 #define APR_BADCH (APR_OS_START_STATUS + 12)
00456
00457 #define APR_BADARG (APR_OS_START_STATUS + 13)
00458
00459 #define APR_EOF (APR_OS_START_STATUS + 14)
00460
00461 #define APR_NOTFOUND (APR_OS_START_STATUS + 15)
00462
00463
00464
00465
00466 #define APR_ANONYMOUS (APR_OS_START_STATUS + 19)
00467
00468 #define APR_FILEBASED (APR_OS_START_STATUS + 20)
00469
00470 #define APR_KEYBASED (APR_OS_START_STATUS + 21)
00471
00472 #define APR_EINIT (APR_OS_START_STATUS + 22)
00473
00474 #define APR_ENOTIMPL (APR_OS_START_STATUS + 23)
00475
00476 #define APR_EMISMATCH (APR_OS_START_STATUS + 24)
00477
00478 #define APR_EBUSY (APR_OS_START_STATUS + 25)
00479
00480
00481
00482
00483
00484
00485
00486
00487
00488
00489
00490 #define APR_STATUS_IS_INCHILD(s) ((s) == APR_INCHILD)
00491
00492
00493
00494
00495
00496
00497 #define APR_STATUS_IS_INPARENT(s) ((s) == APR_INPARENT)
00498
00499
00500
00501
00502
00503
00504 #define APR_STATUS_IS_DETACH(s) ((s) == APR_DETACH)
00505
00506
00507
00508
00509
00510
00511 #define APR_STATUS_IS_NOTDETACH(s) ((s) == APR_NOTDETACH)
00512
00513
00514
00515
00516
00517
00518 #define APR_STATUS_IS_CHILD_DONE(s) ((s) == APR_CHILD_DONE)
00519
00520
00521
00522
00523
00524
00525 #define APR_STATUS_IS_CHILD_NOTDONE(s) ((s) == APR_CHILD_NOTDONE)
00526
00527
00528
00529
00530
00531
00532 #define APR_STATUS_IS_TIMEUP(s) ((s) == APR_TIMEUP)
00533
00534
00535
00536
00537
00538
00539
00540 #define APR_STATUS_IS_INCOMPLETE(s) ((s) == APR_INCOMPLETE)
00541
00542
00543
00544
00545
00546
00547
00548
00549
00550 #define APR_STATUS_IS_BADCH(s) ((s) == APR_BADCH)
00551
00552
00553
00554
00555
00556
00557
00558 #define APR_STATUS_IS_BADARG(s) ((s) == APR_BADARG)
00559
00560
00561
00562
00563
00564
00565 #define APR_STATUS_IS_EOF(s) ((s) == APR_EOF)
00566
00567
00568
00569
00570
00571
00572 #define APR_STATUS_IS_NOTFOUND(s) ((s) == APR_NOTFOUND)
00573
00574
00575
00576
00577
00578
00579
00580
00581
00582 #define APR_STATUS_IS_ANONYMOUS(s) ((s) == APR_ANONYMOUS)
00583
00584
00585
00586
00587
00588
00589 #define APR_STATUS_IS_FILEBASED(s) ((s) == APR_FILEBASED)
00590
00591
00592
00593
00594
00595
00596 #define APR_STATUS_IS_KEYBASED(s) ((s) == APR_KEYBASED)
00597
00598
00599
00600
00601
00602
00603
00604 #define APR_STATUS_IS_EINIT(s) ((s) == APR_EINIT)
00605
00606
00607
00608
00609
00610
00611
00612
00613 #define APR_STATUS_IS_ENOTIMPL(s) ((s) == APR_ENOTIMPL)
00614
00615
00616
00617
00618
00619
00620 #define APR_STATUS_IS_EMISMATCH(s) ((s) == APR_EMISMATCH)
00621
00622
00623
00624
00625
00626 #define APR_STATUS_IS_EBUSY(s) ((s) == APR_EBUSY)
00627
00628
00629
00630
00631
00632
00633
00634
00635
00636 #ifdef EACCES
00637 #define APR_EACCES EACCES
00638 #else
00639 #define APR_EACCES (APR_OS_START_CANONERR + 1)
00640 #endif
00641
00642
00643 #ifdef EEXIST
00644 #define APR_EEXIST EEXIST
00645 #else
00646 #define APR_EEXIST (APR_OS_START_CANONERR + 2)
00647 #endif
00648
00649
00650 #ifdef ENAMETOOLONG
00651 #define APR_ENAMETOOLONG ENAMETOOLONG
00652 #else
00653 #define APR_ENAMETOOLONG (APR_OS_START_CANONERR + 3)
00654 #endif
00655
00656
00657 #ifdef ENOENT
00658 #define APR_ENOENT ENOENT
00659 #else
00660 #define APR_ENOENT (APR_OS_START_CANONERR + 4)
00661 #endif
00662
00663
00664 #ifdef ENOTDIR
00665 #define APR_ENOTDIR ENOTDIR
00666 #else
00667 #define APR_ENOTDIR (APR_OS_START_CANONERR + 5)
00668 #endif
00669
00670
00671 #ifdef ENOSPC
00672 #define APR_ENOSPC ENOSPC
00673 #else
00674 #define APR_ENOSPC (APR_OS_START_CANONERR + 6)
00675 #endif
00676
00677
00678 #ifdef ENOMEM
00679 #define APR_ENOMEM ENOMEM
00680 #else
00681 #define APR_ENOMEM (APR_OS_START_CANONERR + 7)
00682 #endif
00683
00684
00685 #ifdef EMFILE
00686 #define APR_EMFILE EMFILE
00687 #else
00688 #define APR_EMFILE (APR_OS_START_CANONERR + 8)
00689 #endif
00690
00691
00692 #ifdef ENFILE
00693 #define APR_ENFILE ENFILE
00694 #else
00695 #define APR_ENFILE (APR_OS_START_CANONERR + 9)
00696 #endif
00697
00698
00699 #ifdef EBADF
00700 #define APR_EBADF EBADF
00701 #else
00702 #define APR_EBADF (APR_OS_START_CANONERR + 10)
00703 #endif
00704
00705
00706 #ifdef EINVAL
00707 #define APR_EINVAL EINVAL
00708 #else
00709 #define APR_EINVAL (APR_OS_START_CANONERR + 11)
00710 #endif
00711
00712
00713 #ifdef ESPIPE
00714 #define APR_ESPIPE ESPIPE
00715 #else
00716 #define APR_ESPIPE (APR_OS_START_CANONERR + 12)
00717 #endif
00718
00719
00720
00721
00722
00723 #ifdef EAGAIN
00724 #define APR_EAGAIN EAGAIN
00725 #elif defined(EWOULDBLOCK)
00726 #define APR_EAGAIN EWOULDBLOCK
00727 #else
00728 #define APR_EAGAIN (APR_OS_START_CANONERR + 13)
00729 #endif
00730
00731
00732 #ifdef EINTR
00733 #define APR_EINTR EINTR
00734 #else
00735 #define APR_EINTR (APR_OS_START_CANONERR + 14)
00736 #endif
00737
00738
00739 #ifdef ENOTSOCK
00740 #define APR_ENOTSOCK ENOTSOCK
00741 #else
00742 #define APR_ENOTSOCK (APR_OS_START_CANONERR + 15)
00743 #endif
00744
00745
00746 #ifdef ECONNREFUSED
00747 #define APR_ECONNREFUSED ECONNREFUSED
00748 #else
00749 #define APR_ECONNREFUSED (APR_OS_START_CANONERR + 16)
00750 #endif
00751
00752
00753 #ifdef EINPROGRESS
00754 #define APR_EINPROGRESS EINPROGRESS
00755 #else
00756 #define APR_EINPROGRESS (APR_OS_START_CANONERR + 17)
00757 #endif
00758
00759
00760
00761
00762
00763
00764 #ifdef ECONNABORTED
00765 #define APR_ECONNABORTED ECONNABORTED
00766 #else
00767 #define APR_ECONNABORTED (APR_OS_START_CANONERR + 18)
00768 #endif
00769
00770
00771 #ifdef ECONNRESET
00772 #define APR_ECONNRESET ECONNRESET
00773 #else
00774 #define APR_ECONNRESET (APR_OS_START_CANONERR + 19)
00775 #endif
00776
00777
00778
00779 #ifdef ETIMEDOUT
00780 #define APR_ETIMEDOUT ETIMEDOUT
00781 #else
00782 #define APR_ETIMEDOUT (APR_OS_START_CANONERR + 20)
00783 #endif
00784
00785
00786 #ifdef EHOSTUNREACH
00787 #define APR_EHOSTUNREACH EHOSTUNREACH
00788 #else
00789 #define APR_EHOSTUNREACH (APR_OS_START_CANONERR + 21)
00790 #endif
00791
00792
00793 #ifdef ENETUNREACH
00794 #define APR_ENETUNREACH ENETUNREACH
00795 #else
00796 #define APR_ENETUNREACH (APR_OS_START_CANONERR + 22)
00797 #endif
00798
00799
00800 #ifdef EFTYPE
00801 #define APR_EFTYPE EFTYPE
00802 #else
00803 #define APR_EFTYPE (APR_OS_START_CANONERR + 23)
00804 #endif
00805
00806
00807 #ifdef EPIPE
00808 #define APR_EPIPE EPIPE
00809 #else
00810 #define APR_EPIPE (APR_OS_START_CANONERR + 24)
00811 #endif
00812
00813
00814 #ifdef EXDEV
00815 #define APR_EXDEV EXDEV
00816 #else
00817 #define APR_EXDEV (APR_OS_START_CANONERR + 25)
00818 #endif
00819
00820
00821 #ifdef ENOTEMPTY
00822 #define APR_ENOTEMPTY ENOTEMPTY
00823 #else
00824 #define APR_ENOTEMPTY (APR_OS_START_CANONERR + 26)
00825 #endif
00826
00827
00828 #ifdef EAFNOSUPPORT
00829 #define APR_EAFNOSUPPORT EAFNOSUPPORT
00830 #else
00831 #define APR_EAFNOSUPPORT (APR_OS_START_CANONERR + 27)
00832 #endif
00833
00834
00835
00836 #if defined(OS2) && !defined(DOXYGEN)
00837
00838 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR)
00839 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR)
00840
00841 #define INCL_DOSERRORS
00842 #define INCL_DOS
00843
00844
00845
00846
00847
00848
00849
00850
00851
00852
00853
00854
00855 #define apr_get_netos_error() (APR_FROM_OS_ERROR(errno))
00856 #define apr_set_netos_error(e) (errno = APR_TO_OS_ERROR(e))
00857
00858
00859
00860 #define APR_OS2_STATUS(e) (APR_FROM_OS_ERROR(e))
00861
00862
00863
00864
00865 #define SOCBASEERR 10000
00866 #define SOCEPERM (SOCBASEERR+1)
00867 #define SOCESRCH (SOCBASEERR+3)
00868 #define SOCEINTR (SOCBASEERR+4)
00869 #define SOCENXIO (SOCBASEERR+6)
00870 #define SOCEBADF (SOCBASEERR+9)
00871 #define SOCEACCES (SOCBASEERR+13)
00872 #define SOCEFAULT (SOCBASEERR+14)
00873 #define SOCEINVAL (SOCBASEERR+22)
00874 #define SOCEMFILE (SOCBASEERR+24)
00875 #define SOCEPIPE (SOCBASEERR+32)
00876 #define SOCEOS2ERR (SOCBASEERR+100)
00877 #define SOCEWOULDBLOCK (SOCBASEERR+35)
00878 #define SOCEINPROGRESS (SOCBASEERR+36)
00879 #define SOCEALREADY (SOCBASEERR+37)
00880 #define SOCENOTSOCK (SOCBASEERR+38)
00881 #define SOCEDESTADDRREQ (SOCBASEERR+39)
00882 #define SOCEMSGSIZE (SOCBASEERR+40)
00883 #define SOCEPROTOTYPE (SOCBASEERR+41)
00884 #define SOCENOPROTOOPT (SOCBASEERR+42)
00885 #define SOCEPROTONOSUPPORT (SOCBASEERR+43)
00886 #define SOCESOCKTNOSUPPORT (SOCBASEERR+44)
00887 #define SOCEOPNOTSUPP (SOCBASEERR+45)
00888 #define SOCEPFNOSUPPORT (SOCBASEERR+46)
00889 #define SOCEAFNOSUPPORT (SOCBASEERR+47)
00890 #define SOCEADDRINUSE (SOCBASEERR+48)
00891 #define SOCEADDRNOTAVAIL (SOCBASEERR+49)
00892 #define SOCENETDOWN (SOCBASEERR+50)
00893 #define SOCENETUNREACH (SOCBASEERR+51)
00894 #define SOCENETRESET (SOCBASEERR+52)
00895 #define SOCECONNABORTED (SOCBASEERR+53)
00896 #define SOCECONNRESET (SOCBASEERR+54)
00897 #define SOCENOBUFS (SOCBASEERR+55)
00898 #define SOCEISCONN (SOCBASEERR+56)
00899 #define SOCENOTCONN (SOCBASEERR+57)
00900 #define SOCESHUTDOWN (SOCBASEERR+58)
00901 #define SOCETOOMANYREFS (SOCBASEERR+59)
00902 #define SOCETIMEDOUT (SOCBASEERR+60)
00903 #define SOCECONNREFUSED (SOCBASEERR+61)
00904 #define SOCELOOP (SOCBASEERR+62)
00905 #define SOCENAMETOOLONG (SOCBASEERR+63)
00906 #define SOCEHOSTDOWN (SOCBASEERR+64)
00907 #define SOCEHOSTUNREACH (SOCBASEERR+65)
00908 #define SOCENOTEMPTY (SOCBASEERR+66)
00909
00910
00911 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES \
00912 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED \
00913 || (s) == APR_OS_START_SYSERR + ERROR_SHARING_VIOLATION)
00914 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST \
00915 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED \
00916 || (s) == APR_OS_START_SYSERR + ERROR_FILE_EXISTS \
00917 || (s) == APR_OS_START_SYSERR + ERROR_ALREADY_EXISTS \
00918 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED)
00919 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG \
00920 || (s) == APR_OS_START_SYSERR + ERROR_FILENAME_EXCED_RANGE \
00921 || (s) == APR_OS_START_SYSERR + SOCENAMETOOLONG)
00922 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT \
00923 || (s) == APR_OS_START_SYSERR + ERROR_FILE_NOT_FOUND \
00924 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \
00925 || (s) == APR_OS_START_SYSERR + ERROR_NO_MORE_FILES \
00926 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED)
00927 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR)
00928 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC \
00929 || (s) == APR_OS_START_SYSERR + ERROR_DISK_FULL)
00930 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM)
00931 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE \
00932 || (s) == APR_OS_START_SYSERR + ERROR_TOO_MANY_OPEN_FILES)
00933 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE)
00934 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF \
00935 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE)
00936 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL \
00937 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_PARAMETER \
00938 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_FUNCTION)
00939 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE \
00940 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK)
00941 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \
00942 || (s) == APR_OS_START_SYSERR + ERROR_NO_DATA \
00943 || (s) == APR_OS_START_SYSERR + SOCEWOULDBLOCK \
00944 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION)
00945 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \
00946 || (s) == APR_OS_START_SYSERR + SOCEINTR)
00947 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \
00948 || (s) == APR_OS_START_SYSERR + SOCENOTSOCK)
00949 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \
00950 || (s) == APR_OS_START_SYSERR + SOCECONNREFUSED)
00951 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \
00952 || (s) == APR_OS_START_SYSERR + SOCEINPROGRESS)
00953 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \
00954 || (s) == APR_OS_START_SYSERR + SOCECONNABORTED)
00955 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \
00956 || (s) == APR_OS_START_SYSERR + SOCECONNRESET)
00957
00958 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \
00959 || (s) == APR_OS_START_SYSERR + SOCETIMEDOUT)
00960 #undef APR_STATUS_IS_TIMEUP
00961 #define APR_STATUS_IS_TIMEUP(s) ((s) == APR_TIMEUP \
00962 || (s) == APR_OS_START_SYSERR + SOCETIMEDOUT)
00963 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \
00964 || (s) == APR_OS_START_SYSERR + SOCEHOSTUNREACH)
00965 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \
00966 || (s) == APR_OS_START_SYSERR + SOCENETUNREACH)
00967 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE)
00968 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE \
00969 || (s) == APR_OS_START_SYSERR + ERROR_BROKEN_PIPE \
00970 || (s) == APR_OS_START_SYSERR + SOCEPIPE)
00971 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV \
00972 || (s) == APR_OS_START_SYSERR + ERROR_NOT_SAME_DEVICE)
00973 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY \
00974 || (s) == APR_OS_START_SYSERR + ERROR_DIR_NOT_EMPTY \
00975 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED)
00976 #define APR_STATUS_IS_EAFNOSUPPORT(s) ((s) == APR_AFNOSUPPORT \
00977 || (s) == APR_OS_START_SYSERR + SOCEAFNOSUPPORT)
00978
00979
00980
00981
00982
00983
00984
00985
00986
00987
00988
00989
00990
00991
00992
00993
00994
00995
00996
00997
00998
00999
01000
01001
01002
01003
01004
01005
01006
01007
01008 #elif defined(WIN32) && !defined(DOXYGEN)
01009
01010 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR)
01011 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR)
01012
01013 #define apr_get_os_error() (APR_FROM_OS_ERROR(GetLastError()))
01014 #define apr_set_os_error(e) (SetLastError(APR_TO_OS_ERROR(e)))
01015
01016
01017
01018 #define apr_get_netos_error() (APR_FROM_OS_ERROR(WSAGetLastError()))
01019 #define apr_set_netos_error(e) (WSASetLastError(APR_TO_OS_ERROR(e)))
01020
01021
01022 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES \
01023 || (s) == APR_OS_START_SYSERR + ERROR_ACCESS_DENIED \
01024 || (s) == APR_OS_START_SYSERR + ERROR_CANNOT_MAKE \
01025 || (s) == APR_OS_START_SYSERR + ERROR_CURRENT_DIRECTORY \
01026 || (s) == APR_OS_START_SYSERR + ERROR_DRIVE_LOCKED \
01027 || (s) == APR_OS_START_SYSERR + ERROR_FAIL_I24 \
01028 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION \
01029 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_FAILED \
01030 || (s) == APR_OS_START_SYSERR + ERROR_NOT_LOCKED \
01031 || (s) == APR_OS_START_SYSERR + ERROR_NETWORK_ACCESS_DENIED \
01032 || (s) == APR_OS_START_SYSERR + ERROR_SHARING_VIOLATION)
01033 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST \
01034 || (s) == APR_OS_START_SYSERR + ERROR_FILE_EXISTS \
01035 || (s) == APR_OS_START_SYSERR + ERROR_ALREADY_EXISTS)
01036 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG \
01037 || (s) == APR_OS_START_SYSERR + ERROR_FILENAME_EXCED_RANGE \
01038 || (s) == APR_OS_START_SYSERR + WSAENAMETOOLONG)
01039 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT \
01040 || (s) == APR_OS_START_SYSERR + ERROR_FILE_NOT_FOUND \
01041 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \
01042 || (s) == APR_OS_START_SYSERR + ERROR_OPEN_FAILED \
01043 || (s) == APR_OS_START_SYSERR + ERROR_NO_MORE_FILES)
01044 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR \
01045 || (s) == APR_OS_START_SYSERR + ERROR_PATH_NOT_FOUND \
01046 || (s) == APR_OS_START_SYSERR + ERROR_BAD_NETPATH \
01047 || (s) == APR_OS_START_SYSERR + ERROR_BAD_NET_NAME \
01048 || (s) == APR_OS_START_SYSERR + ERROR_BAD_PATHNAME \
01049 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DRIVE)
01050 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC \
01051 || (s) == APR_OS_START_SYSERR + ERROR_DISK_FULL)
01052 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM \
01053 || (s) == APR_OS_START_SYSERR + ERROR_ARENA_TRASHED \
01054 || (s) == APR_OS_START_SYSERR + ERROR_NOT_ENOUGH_MEMORY \
01055 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_BLOCK \
01056 || (s) == APR_OS_START_SYSERR + ERROR_NOT_ENOUGH_QUOTA \
01057 || (s) == APR_OS_START_SYSERR + ERROR_OUTOFMEMORY)
01058 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE \
01059 || (s) == APR_OS_START_SYSERR + ERROR_TOO_MANY_OPEN_FILES)
01060 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE)
01061 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF \
01062 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE \
01063 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_TARGET_HANDLE)
01064 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL \
01065 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_ACCESS \
01066 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DATA \
01067 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_FUNCTION \
01068 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_HANDLE \
01069 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_PARAMETER \
01070 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK)
01071 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE \
01072 || (s) == APR_OS_START_SYSERR + ERROR_SEEK_ON_DEVICE \
01073 || (s) == APR_OS_START_SYSERR + ERROR_NEGATIVE_SEEK)
01074 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \
01075 || (s) == APR_OS_START_SYSERR + ERROR_NO_DATA \
01076 || (s) == APR_OS_START_SYSERR + ERROR_NO_PROC_SLOTS \
01077 || (s) == APR_OS_START_SYSERR + ERROR_NESTING_NOT_ALLOWED \
01078 || (s) == APR_OS_START_SYSERR + ERROR_MAX_THRDS_REACHED \
01079 || (s) == APR_OS_START_SYSERR + ERROR_LOCK_VIOLATION \
01080 || (s) == APR_OS_START_SYSERR + WSAEWOULDBLOCK)
01081 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \
01082 || (s) == APR_OS_START_SYSERR + WSAEINTR)
01083 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \
01084 || (s) == APR_OS_START_SYSERR + WSAENOTSOCK)
01085 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \
01086 || (s) == APR_OS_START_SYSERR + WSAECONNREFUSED)
01087 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \
01088 || (s) == APR_OS_START_SYSERR + WSAEINPROGRESS)
01089 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \
01090 || (s) == APR_OS_START_SYSERR + WSAECONNABORTED)
01091 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \
01092 || (s) == APR_OS_START_SYSERR + ERROR_NETNAME_DELETED \
01093 || (s) == APR_OS_START_SYSERR + WSAECONNRESET)
01094
01095 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \
01096 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \
01097 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT)
01098 #undef APR_STATUS_IS_TIMEUP
01099 #define APR_STATUS_IS_TIMEUP(s) ((s) == APR_TIMEUP \
01100 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \
01101 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT)
01102 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \
01103 || (s) == APR_OS_START_SYSERR + WSAEHOSTUNREACH)
01104 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \
01105 || (s) == APR_OS_START_SYSERR + WSAENETUNREACH)
01106 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE \
01107 || (s) == APR_OS_START_SYSERR + ERROR_EXE_MACHINE_TYPE_MISMATCH \
01108 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_DLL \
01109 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_MODULETYPE \
01110 || (s) == APR_OS_START_SYSERR + ERROR_BAD_EXE_FORMAT \
01111 || (s) == APR_OS_START_SYSERR + ERROR_INVALID_EXE_SIGNATURE \
01112 || (s) == APR_OS_START_SYSERR + ERROR_FILE_CORRUPT \
01113 || (s) == APR_OS_START_SYSERR + ERROR_BAD_FORMAT)
01114 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE \
01115 || (s) == APR_OS_START_SYSERR + ERROR_BROKEN_PIPE)
01116 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV \
01117 || (s) == APR_OS_START_SYSERR + ERROR_NOT_SAME_DEVICE)
01118 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY \
01119 || (s) == APR_OS_START_SYSERR + ERROR_DIR_NOT_EMPTY)
01120 #define APR_STATUS_IS_EAFNOSUPPORT(s) ((s) == APR_EAFNOSUPPORT \
01121 || (s) == APR_OS_START_SYSERR + WSAEAFNOSUPPORT)
01122
01123 #elif defined(NETWARE) && defined(USE_WINSOCK) && !defined(DOXYGEN)
01124
01125 #define APR_FROM_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e + APR_OS_START_SYSERR)
01126 #define APR_TO_OS_ERROR(e) (e == 0 ? APR_SUCCESS : e - APR_OS_START_SYSERR)
01127
01128 #define apr_get_os_error() (errno)
01129 #define apr_set_os_error(e) (errno = (e))
01130
01131
01132 #define apr_get_netos_error() (APR_FROM_OS_ERROR(WSAGetLastError()))
01133 #define apr_set_netos_error(e) (WSASetLastError(APR_TO_OS_ERROR(e)))
01134
01135
01136 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES)
01137 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST)
01138 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG)
01139 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT)
01140 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR)
01141 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC)
01142 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM)
01143 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE)
01144 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE)
01145 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF)
01146 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL)
01147 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE)
01148
01149 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \
01150 || (s) == EWOULDBLOCK \
01151 || (s) == APR_OS_START_SYSERR + WSAEWOULDBLOCK)
01152 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR \
01153 || (s) == APR_OS_START_SYSERR + WSAEINTR)
01154 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK \
01155 || (s) == APR_OS_START_SYSERR + WSAENOTSOCK)
01156 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED \
01157 || (s) == APR_OS_START_SYSERR + WSAECONNREFUSED)
01158 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS \
01159 || (s) == APR_OS_START_SYSERR + WSAEINPROGRESS)
01160 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \
01161 || (s) == APR_OS_START_SYSERR + WSAECONNABORTED)
01162 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET \
01163 || (s) == APR_OS_START_SYSERR + WSAECONNRESET)
01164
01165 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT \
01166 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \
01167 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT)
01168 #undef APR_STATUS_IS_TIMEUP
01169 #define APR_STATUS_IS_TIMEUP(s) ((s) == APR_TIMEUP \
01170 || (s) == APR_OS_START_SYSERR + WSAETIMEDOUT \
01171 || (s) == APR_OS_START_SYSERR + WAIT_TIMEOUT)
01172 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH \
01173 || (s) == APR_OS_START_SYSERR + WSAEHOSTUNREACH)
01174 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH \
01175 || (s) == APR_OS_START_SYSERR + WSAENETUNREACH)
01176 #define APR_STATUS_IS_ENETDOWN(s) ((s) == APR_OS_START_SYSERR + WSAENETDOWN)
01177 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE)
01178 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE)
01179 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV)
01180 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY)
01181 #define APR_STATUS_IS_EAFNOSUPPORT(s) ((s) == APR_EAFNOSUPPORT \
01182 || (s) == APR_OS_START_SYSERR + WSAEAFNOSUPPORT)
01183
01184 #else
01185
01186
01187
01188
01189 #define APR_FROM_OS_ERROR(e) (e)
01190 #define APR_TO_OS_ERROR(e) (e)
01191
01192 #define apr_get_os_error() (errno)
01193 #define apr_set_os_error(e) (errno = (e))
01194
01195
01196
01197 #define apr_get_netos_error() (errno)
01198 #define apr_set_netos_error(e) (errno = (e))
01199
01200
01201
01202
01203
01204
01205
01206 #define APR_STATUS_IS_EACCES(s) ((s) == APR_EACCES)
01207
01208 #define APR_STATUS_IS_EEXIST(s) ((s) == APR_EEXIST)
01209
01210 #define APR_STATUS_IS_ENAMETOOLONG(s) ((s) == APR_ENAMETOOLONG)
01211
01212
01213
01214
01215
01216
01217 #ifdef EMVSCATLG
01218 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT \
01219 || (s) == EMVSCATLG)
01220 #else
01221 #define APR_STATUS_IS_ENOENT(s) ((s) == APR_ENOENT)
01222 #endif
01223
01224 #define APR_STATUS_IS_ENOTDIR(s) ((s) == APR_ENOTDIR)
01225
01226 #ifdef EDQUOT
01227 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC \
01228 || (s) == EDQUOT)
01229 #else
01230 #define APR_STATUS_IS_ENOSPC(s) ((s) == APR_ENOSPC)
01231 #endif
01232
01233 #define APR_STATUS_IS_ENOMEM(s) ((s) == APR_ENOMEM)
01234
01235 #define APR_STATUS_IS_EMFILE(s) ((s) == APR_EMFILE)
01236
01237 #define APR_STATUS_IS_ENFILE(s) ((s) == APR_ENFILE)
01238
01239 #define APR_STATUS_IS_EBADF(s) ((s) == APR_EBADF)
01240
01241 #define APR_STATUS_IS_EINVAL(s) ((s) == APR_EINVAL)
01242
01243 #define APR_STATUS_IS_ESPIPE(s) ((s) == APR_ESPIPE)
01244
01245
01246 #if !defined(EWOULDBLOCK) || !defined(EAGAIN)
01247 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN)
01248 #elif (EWOULDBLOCK == EAGAIN)
01249 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN)
01250 #else
01251 #define APR_STATUS_IS_EAGAIN(s) ((s) == APR_EAGAIN \
01252 || (s) == EWOULDBLOCK)
01253 #endif
01254
01255
01256 #define APR_STATUS_IS_EINTR(s) ((s) == APR_EINTR)
01257
01258 #define APR_STATUS_IS_ENOTSOCK(s) ((s) == APR_ENOTSOCK)
01259
01260 #define APR_STATUS_IS_ECONNREFUSED(s) ((s) == APR_ECONNREFUSED)
01261
01262 #define APR_STATUS_IS_EINPROGRESS(s) ((s) == APR_EINPROGRESS)
01263
01264
01265
01266
01267
01268
01269
01270
01271
01272
01273
01274
01275 #ifdef EPROTO
01276 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED \
01277 || (s) == EPROTO)
01278 #else
01279 #define APR_STATUS_IS_ECONNABORTED(s) ((s) == APR_ECONNABORTED)
01280 #endif
01281
01282
01283 #define APR_STATUS_IS_ECONNRESET(s) ((s) == APR_ECONNRESET)
01284
01285
01286 #define APR_STATUS_IS_ETIMEDOUT(s) ((s) == APR_ETIMEDOUT)
01287
01288 #define APR_STATUS_IS_EHOSTUNREACH(s) ((s) == APR_EHOSTUNREACH)
01289
01290 #define APR_STATUS_IS_ENETUNREACH(s) ((s) == APR_ENETUNREACH)
01291
01292 #define APR_STATUS_IS_EFTYPE(s) ((s) == APR_EFTYPE)
01293
01294 #define APR_STATUS_IS_EPIPE(s) ((s) == APR_EPIPE)
01295
01296 #define APR_STATUS_IS_EXDEV(s) ((s) == APR_EXDEV)
01297
01298 #define APR_STATUS_IS_ENOTEMPTY(s) ((s) == APR_ENOTEMPTY || \
01299 (s) == APR_EEXIST)
01300
01301 #define APR_STATUS_IS_EAFNOSUPPORT(s) ((s) == APR_EAFNOSUPPORT)
01302
01303
01304 #endif
01305
01306
01307
01308 #ifdef __cplusplus
01309 }
01310 #endif
01311
01312 #endif