1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
//! macOS error numbers (`<sys/errno.h>`).
/// Operation not permitted.
pub const EPERM: i32 = 1;
/// No such file or directory.
pub const ENOENT: i32 = 2;
/// No such process.
pub const ESRCH: i32 = 3;
/// Interrupted system call.
pub const EINTR: i32 = 4;
/// I/O error.
pub const EIO: i32 = 5;
/// No such device or address.
pub const ENXIO: i32 = 6;
/// Argument list too long.
pub const E2BIG: i32 = 7;
/// Exec format error.
pub const ENOEXEC: i32 = 8;
/// Bad file number.
pub const EBADF: i32 = 9;
/// No child processes.
pub const ECHILD: i32 = 10;
/// Resource deadlock would occur.
pub const EDEADLK: i32 = 11;
/// Out of memory.
pub const ENOMEM: i32 = 12;
/// Permission denied.
pub const EACCES: i32 = 13;
/// Bad address.
pub const EFAULT: i32 = 14;
/// Block device required.
pub const ENOTBLK: i32 = 15;
/// Device or resource busy.
pub const EBUSY: i32 = 16;
/// File exists.
pub const EEXIST: i32 = 17;
/// Cross-device link.
pub const EXDEV: i32 = 18;
/// No such device.
pub const ENODEV: i32 = 19;
/// Not a directory.
pub const ENOTDIR: i32 = 20;
/// Is a directory.
pub const EISDIR: i32 = 21;
/// Invalid argument.
pub const EINVAL: i32 = 22;
/// File table overflow.
pub const ENFILE: i32 = 23;
/// Too many open files.
pub const EMFILE: i32 = 24;
/// Not a typewriter.
pub const ENOTTY: i32 = 25;
/// Text file busy.
pub const ETXTBSY: i32 = 26;
/// File too large.
pub const EFBIG: i32 = 27;
/// No space left on device.
pub const ENOSPC: i32 = 28;
/// Illegal seek.
pub const ESPIPE: i32 = 29;
/// Read-only file system.
pub const EROFS: i32 = 30;
/// Too many links.
pub const EMLINK: i32 = 31;
/// Broken pipe.
pub const EPIPE: i32 = 32;
/// Math argument out of domain of func.
pub const EDOM: i32 = 33;
/// Math result not representable.
pub const ERANGE: i32 = 34;
/// Try again.
pub const EAGAIN: i32 = 35;
/// Operation now in progress.
pub const EINPROGRESS: i32 = 36;
/// Operation already in progress.
pub const EALREADY: i32 = 37;
/// Socket operation on non-socket.
pub const ENOTSOCK: i32 = 38;
/// Destination address required.
pub const EDESTADDRREQ: i32 = 39;
/// Message too long.
pub const EMSGSIZE: i32 = 40;
/// Protocol wrong type for socket.
pub const EPROTOTYPE: i32 = 41;
/// Protocol not available.
pub const ENOPROTOOPT: i32 = 42;
/// Protocol not supported.
pub const EPROTONOSUPPORT: i32 = 43;
/// Socket type not supported.
pub const ESOCKTNOSUPPORT: i32 = 44;
/// Operation not supported.
pub const ENOTSUP: i32 = 45;
/// Protocol family not supported.
pub const EPFNOSUPPORT: i32 = 46;
/// Address family not supported by protocol.
pub const EAFNOSUPPORT: i32 = 47;
/// Address already in use.
pub const EADDRINUSE: i32 = 48;
/// Cannot assign requested address.
pub const EADDRNOTAVAIL: i32 = 49;
/// Network is down.
pub const ENETDOWN: i32 = 50;
/// Network is unreachable.
pub const ENETUNREACH: i32 = 51;
/// Network dropped connection because of reset.
pub const ENETRESET: i32 = 52;
/// Software caused connection abort.
pub const ECONNABORTED: i32 = 53;
/// Connection reset by peer.
pub const ECONNRESET: i32 = 54;
/// No buffer space available.
pub const ENOBUFS: i32 = 55;
/// Transport endpoint is already connected.
pub const EISCONN: i32 = 56;
/// Transport endpoint is not connected.
pub const ENOTCONN: i32 = 57;
/// Cannot send after transport endpoint shutdown.
pub const ESHUTDOWN: i32 = 58;
/// Too many references: cannot splice.
pub const ETOOMANYREFS: i32 = 59;
/// Connection timed out.
pub const ETIMEDOUT: i32 = 60;
/// Connection refused.
pub const ECONNREFUSED: i32 = 61;
/// Too many symbolic links encountered.
pub const ELOOP: i32 = 62;
/// File name too long.
pub const ENAMETOOLONG: i32 = 63;
/// Host is down.
pub const EHOSTDOWN: i32 = 64;
/// No route to host.
pub const EHOSTUNREACH: i32 = 65;
/// Directory not empty.
pub const ENOTEMPTY: i32 = 66;
/// Too many processes.
pub const EPROCLIM: i32 = 67;
/// Too many users.
pub const EUSERS: i32 = 68;
/// Quota exceeded.
pub const EDQUOT: i32 = 69;
/// Stale file handle.
pub const ESTALE: i32 = 70;
/// Object is remote.
pub const EREMOTE: i32 = 71;
/// RPC struct is bad.
pub const EBADRPC: i32 = 72;
/// RPC version wrong.
pub const ERPCMISMATCH: i32 = 73;
/// RPC program not available.
pub const EPROGUNAVAIL: i32 = 74;
/// Program version wrong.
pub const EPROGMISMATCH: i32 = 75;
/// Bad procedure for program.
pub const EPROCUNAVAIL: i32 = 76;
/// No record locks available.
pub const ENOLCK: i32 = 77;
/// Invalid system call number.
pub const ENOSYS: i32 = 78;
/// Inappropriate file type or format.
pub const EFTYPE: i32 = 79;
/// Authentication error.
pub const EAUTH: i32 = 80;
/// Need authenticator.
pub const ENEEDAUTH: i32 = 81;
/// Device power is off.
pub const EPWROFF: i32 = 82;
/// Device error.
pub const EDEVERR: i32 = 83;
/// Value too large for defined data type.
pub const EOVERFLOW: i32 = 84;
/// Bad executable.
pub const EBADEXEC: i32 = 85;
/// Bad CPU type in executable.
pub const EBADARCH: i32 = 86;
/// Shared library version mismatch.
pub const ESHLIBVERS: i32 = 87;
/// Malformed Mach-O file.
pub const EBADMACHO: i32 = 88;
/// Operation Canceled.
pub const ECANCELED: i32 = 89;
/// Identifier removed.
pub const EIDRM: i32 = 90;
/// No message of desired type.
pub const ENOMSG: i32 = 91;
/// Illegal byte sequence.
pub const EILSEQ: i32 = 92;
/// Attribute not found.
pub const ENOATTR: i32 = 93;
/// Not a data message.
pub const EBADMSG: i32 = 94;
/// Multihop attempted.
pub const EMULTIHOP: i32 = 95;
/// No data available.
pub const ENODATA: i32 = 96;
/// Link has been severed.
pub const ENOLINK: i32 = 97;
/// Out of streams resources.
pub const ENOSR: i32 = 98;
/// Device not a stream.
pub const ENOSTR: i32 = 99;
/// Protocol error.
pub const EPROTO: i32 = 100;
/// Timer expired.
pub const ETIME: i32 = 101;
/// Operation not supported on transport endpoint.
pub const EOPNOTSUPP: i32 = 102;