]> pd.if.org Git - pdclib/blob - includes/errno.h
Moved errno to main codebase.
[pdclib] / includes / errno.h
1 /* Errors <errno.h>
2
3    This file is part of the Public Domain C Library (PDCLib).
4    Permission is granted to use, modify, and / or redistribute at will.
5 */
6
7 #ifndef _PDCLIB_ERRNO_H
8 #define _PDCLIB_ERRNO_H _PDCLIB_ERRNO_H
9
10 #include "_PDCLIB_int.h"
11
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15
16 extern int * _PDCLIB_errno_func( void );
17 #define errno (*_PDCLIB_errno_func())
18
19 /* C only requires the following three */
20 #define ERANGE          _PDCLIB_ERANGE
21 #define EDOM            _PDCLIB_EDOM
22 #define EILSEQ          _PDCLIB_EILSEQ
23
24 /* C++11 additionally requires the following (taken from POSIX) */
25 #define E2BIG           _PDCLIB_E2BIG
26 #define EACCES          _PDCLIB_EACCES
27 #define EADDRINUSE      _PDCLIB_EADDRINUSE
28 #define EADDRNOTAVAIL   _PDCLIB_EADDRNOTAVAIL
29 #define EAFNOSUPPORT    _PDCLIB_EAFNOSUPPORT
30 #define EAGAIN          _PDCLIB_EAGAIN
31 #define EALREADY        _PDCLIB_EALREADY
32 #define EBADF           _PDCLIB_EBADF
33 #define EBADMSG         _PDCLIB_EBADMSG
34 #define EBUSY           _PDCLIB_EBUSY
35 #define ECANCELED       _PDCLIB_ECANCELED
36 #define ECHILD          _PDCLIB_ECHILD
37 #define ECONNABORTED    _PDCLIB_ECONNABORTED
38 #define ECONNREFUSED    _PDCLIB_ECONNREFUSED
39 #define ECONNRESET      _PDCLIB_ECONNRESET
40 #define EDEADLK         _PDCLIB_EDEADLK
41 #define EDESTADDRREQ    _PDCLIB_EDESTADDRREQ
42 #define EEXIST          _PDCLIB_EEXIST
43 #define EFAULT          _PDCLIB_EFAULT
44 #define EFBIG           _PDCLIB_EFBIG
45 #define EHOSTUNREACH    _PDCLIB_EHOSTUNREACH
46 #define EIDRM           _PDCLIB_EIDRM
47 #define EINPROGRESS     _PDCLIB_EINPROGRESS
48 #define EINTR           _PDCLIB_EINTR
49 #define EINVAL          _PDCLIB_EINVAL
50 #define EIO             _PDCLIB_EIO
51 #define EISCONN         _PDCLIB_EISCONN
52 #define EISDIR          _PDCLIB_EISDIR
53 #define ELOOP           _PDCLIB_ELOOP
54 #define EMFILE          _PDCLIB_EMFILE
55 #define EMLINK          _PDCLIB_EMLINK
56 #define EMSGSIZE        _PDCLIB_EMSGSIZE
57 #define ENAMETOOLONG    _PDCLIB_ENAMETOOLONG
58 #define ENETDOWN        _PDCLIB_ENETDOWN
59 #define ENETRESET       _PDCLIB_ENETRESET
60 #define ENETUNREACH     _PDCLIB_ENETUNREACH
61 #define ENFILE          _PDCLIB_ENFILE
62 #define ENOBUFS         _PDCLIB_ENOBUFS
63 #define ENODATA         _PDCLIB_ENODATA
64 #define ENODEV          _PDCLIB_ENODEV
65 #define ENOENT          _PDCLIB_ENOENT
66 #define ENOEXEC         _PDCLIB_ENOEXEC
67 #define ENOLCK          _PDCLIB_ENOLCK
68 #define ENOLINK         _PDCLIB_ENOLINK
69 #define ENOMEM          _PDCLIB_ENOMEM
70 #define ENOMSG          _PDCLIB_ENOMSG
71 #define ENOPROTOOPT     _PDCLIB_ENOPROTOOPT
72 #define ENOSPC          _PDCLIB_ENOSPC
73 #define ENOSR           _PDCLIB_ENOSR
74 #define ENOSTR          _PDCLIB_ENOSTR
75 #define ENOSYS          _PDCLIB_ENOSYS
76 #define ENOTCONN        _PDCLIB_ENOTCONN
77 #define ENOTDIR         _PDCLIB_ENOTDIR
78 #define ENOTEMPTY       _PDCLIB_ENOTEMPTY
79 #define ENOTRECOVERABLE _PDCLIB_ENOTRECOVERABLE
80 #define ENOTSOCK        _PDCLIB_ENOTSOCK
81 #define ENOTSUP         _PDCLIB_ENOTSUP
82 #define ENOTTY          _PDCLIB_ENOTTY
83 #define ENXIO           _PDCLIB_ENXIO
84 #define EOPNOTSUPP      _PDCLIB_EOPNOTSUPP
85 #define EOVERFLOW       _PDCLIB_EOVERFLOW
86 #define EOWNERDEAD      _PDCLIB_EOWNERDEAD
87 #define EPERM           _PDCLIB_EPERM
88 #define EPIPE           _PDCLIB_EPIPE
89 #define EPROTO          _PDCLIB_EPROTO
90 #define EPROTONOSUPPORT _PDCLIB_EPROTONOSUPPORT
91 #define EPROTOTYPE      _PDCLIB_EPROTOTYPE
92 #define EROFS           _PDCLIB_EROFS
93 #define ESPIPE          _PDCLIB_ESPIPE
94 #define ESRCH           _PDCLIB_ESRCH
95 #define ETIME           _PDCLIB_ETIME
96 #define ETIMEDOUT       _PDCLIB_ETIMEDOUT
97 #define ETXTBSY         _PDCLIB_ETXTBSY
98 #define EWOULDBLOCK     _PDCLIB_EWOULDBLOCK
99 #define EXDEV           _PDCLIB_EXDEV
100
101 #ifdef __cplusplus
102 }
103 #endif
104
105 #endif