#![allow(dead_code)]
use crate::Errno;
impl Errno {
pub const ERELOOKUP: Self = Self(-5);
pub const EDIRIOCTL: Self = Self(-4);
pub const ENOIOCTL: Self = Self(-3);
pub const EJUSTRETURN: Self = Self(-2);
pub const ERESTART: Self = Self(-1);
pub const EPERM: Self = Self(1);
pub const ENOENT: Self = Self(2);
pub const ESRCH: Self = Self(3);
pub const EINTR: Self = Self(4);
pub const EIO: Self = Self(5);
pub const ENXIO: Self = Self(6);
pub const E2BIG: Self = Self(7);
pub const ENOEXEC: Self = Self(8);
pub const EBADF: Self = Self(9);
pub const ECHILD: Self = Self(10);
pub const EDEADLK: Self = Self(11);
pub const ENOMEM: Self = Self(12);
pub const EACCES: Self = Self(13);
pub const EFAULT: Self = Self(14);
pub const ENOTBLK: Self = Self(15);
pub const EBUSY: Self = Self(16);
pub const EEXIST: Self = Self(17);
pub const EXDEV: Self = Self(18);
pub const ENODEV: Self = Self(19);
pub const ENOTDIR: Self = Self(20);
pub const EISDIR: Self = Self(21);
pub const EINVAL: Self = Self(22);
pub const ENFILE: Self = Self(23);
pub const EMFILE: Self = Self(24);
pub const ENOTTY: Self = Self(25);
pub const ETXTBSY: Self = Self(26);
pub const EFBIG: Self = Self(27);
pub const ENOSPC: Self = Self(28);
pub const ESPIPE: Self = Self(29);
pub const EROFS: Self = Self(30);
pub const EMLINK: Self = Self(31);
pub const EPIPE: Self = Self(32);
pub const EDOM: Self = Self(33);
pub const ERANGE: Self = Self(34);
pub const EAGAIN: Self = Self(35);
pub const EINPROGRESS: Self = Self(36);
pub const EALREADY: Self = Self(37);
pub const ENOTSOCK: Self = Self(38);
pub const EDESTADDRREQ: Self = Self(39);
pub const EMSGSIZE: Self = Self(40);
pub const EPROTOTYPE: Self = Self(41);
pub const ENOPROTOOPT: Self = Self(42);
pub const EPROTONOSUPPORT: Self = Self(43);
pub const ESOCKTNOSUPPORT: Self = Self(44);
pub const EOPNOTSUPP: Self = Self(45);
pub const EPFNOSUPPORT: Self = Self(46);
pub const EAFNOSUPPORT: Self = Self(47);
pub const EADDRINUSE: Self = Self(48);
pub const EADDRNOTAVAIL: Self = Self(49);
pub const ENETDOWN: Self = Self(50);
pub const ENETUNREACH: Self = Self(51);
pub const ENETRESET: Self = Self(52);
pub const ECONNABORTED: Self = Self(53);
pub const ECONNRESET: Self = Self(54);
pub const ENOBUFS: Self = Self(55);
pub const EISCONN: Self = Self(56);
pub const ENOTCONN: Self = Self(57);
pub const ESHUTDOWN: Self = Self(58);
pub const ETOOMANYREFS: Self = Self(59);
pub const ETIMEDOUT: Self = Self(60);
pub const ECONNREFUSED: Self = Self(61);
pub const ELOOP: Self = Self(62);
pub const ENAMETOOLONG: Self = Self(63);
pub const EHOSTDOWN: Self = Self(64);
pub const EHOSTUNREACH: Self = Self(65);
pub const ENOTEMPTY: Self = Self(66);
pub const EPROCLIM: Self = Self(67);
pub const EUSERS: Self = Self(68);
pub const EDQUOT: Self = Self(69);
pub const ESTALE: Self = Self(70);
pub const EREMOTE: Self = Self(71);
pub const EBADRPC: Self = Self(72);
pub const ERPCMISMATCH: Self = Self(73);
pub const EPROGUNAVAIL: Self = Self(74);
pub const EPROGMISMATCH: Self = Self(75);
pub const EPROCUNAVAIL: Self = Self(76);
pub const ENOLCK: Self = Self(77);
pub const ENOSYS: Self = Self(78);
pub const EFTYPE: Self = Self(79);
pub const EAUTH: Self = Self(80);
pub const ENEEDAUTH: Self = Self(81);
pub const EIDRM: Self = Self(82);
pub const ENOMSG: Self = Self(83);
pub const EOVERFLOW: Self = Self(84);
pub const ECANCELED: Self = Self(85);
pub const EILSEQ: Self = Self(86);
pub const ENOATTR: Self = Self(87);
pub const EDOOFUS: Self = Self(88);
pub const EBADMSG: Self = Self(89);
pub const EMULTIHOP: Self = Self(90);
pub const ENOLINK: Self = Self(91);
pub const EPROTO: Self = Self(92);
pub const ENOTCAPABLE: Self = Self(93);
pub const ECAPMODE: Self = Self(94);
pub const ENOTRECOVERABLE: Self = Self(95);
pub const EOWNERDEAD: Self = Self(96);
pub const EINTEGRITY: Self = Self(97);
pub const ENOTSUP: Self = Self::EOPNOTSUPP;
pub const EWOULDBLOCK: Self = Self::EAGAIN;
pub const MIN: i32 = -5;
pub const MAX: i32 = 97;
#[cfg(feature = "iter")]
pub(crate) const ALL: [i32; 102] = [
-5, -4, -3, -2, -1, 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,
];
pub(crate) fn name_and_description(&self) -> Option<(&'static str, &'static str)> {
match self.0 {
-5 => Some(("ERELOOKUP", "retry the directory lookup")),
-4 => Some(("EDIRIOCTL", "do direct ioctl in GEOM")),
-3 => Some(("ENOIOCTL", "ioctl not handled by this layer")),
-2 => Some(("EJUSTRETURN", "don't modify regs, just return")),
-1 => Some(("ERESTART", "restart syscall")),
1 => Some(("EPERM", "Operation not permitted")),
2 => Some(("ENOENT", "No such file or directory")),
3 => Some(("ESRCH", "No such process")),
4 => Some(("EINTR", "Interrupted system call")),
5 => Some(("EIO", "Input/output error")),
6 => Some(("ENXIO", "Device not configured")),
7 => Some(("E2BIG", "Argument list too long")),
8 => Some(("ENOEXEC", "Exec format error")),
9 => Some(("EBADF", "Bad file descriptor")),
10 => Some(("ECHILD", "No child processes")),
11 => Some(("EDEADLK", "Resource deadlock avoided")),
12 => Some(("ENOMEM", "Cannot allocate memory")),
13 => Some(("EACCES", "Permission denied")),
14 => Some(("EFAULT", "Bad address")),
15 => Some(("ENOTBLK", "Block device required")),
16 => Some(("EBUSY", "Device busy")),
17 => Some(("EEXIST", "File exists")),
18 => Some(("EXDEV", "Cross-device link")),
19 => Some(("ENODEV", "Operation not supported by device")),
20 => Some(("ENOTDIR", "Not a directory")),
21 => Some(("EISDIR", "Is a directory")),
22 => Some(("EINVAL", "Invalid argument")),
23 => Some(("ENFILE", "Too many open files in system")),
24 => Some(("EMFILE", "Too many open files")),
25 => Some(("ENOTTY", "Inappropriate ioctl for device")),
26 => Some(("ETXTBSY", "Text file busy")),
27 => Some(("EFBIG", "File too large")),
28 => Some(("ENOSPC", "No space left on device")),
29 => Some(("ESPIPE", "Illegal seek")),
30 => Some(("EROFS", "Read-only filesystem")),
31 => Some(("EMLINK", "Too many links")),
32 => Some(("EPIPE", "Broken pipe")),
33 => Some(("EDOM", "Numerical argument out of domain")),
34 => Some(("ERANGE", "Result too large")),
35 => Some(("EAGAIN", "Resource temporarily unavailable")),
36 => Some(("EINPROGRESS", "Operation now in progress")),
37 => Some(("EALREADY", "Operation already in progress")),
38 => Some(("ENOTSOCK", "Socket operation on non-socket")),
39 => Some(("EDESTADDRREQ", "Destination address required")),
40 => Some(("EMSGSIZE", "Message too long")),
41 => Some(("EPROTOTYPE", "Protocol wrong type for socket")),
42 => Some(("ENOPROTOOPT", "Protocol not available")),
43 => Some(("EPROTONOSUPPORT", "Protocol not supported")),
44 => Some(("ESOCKTNOSUPPORT", "Socket type not supported")),
45 => Some(("EOPNOTSUPP", "Operation not supported")),
46 => Some(("EPFNOSUPPORT", "Protocol family not supported")),
47 => Some((
"EAFNOSUPPORT",
"Address family not supported by protocol family",
)),
48 => Some(("EADDRINUSE", "Address already in use")),
49 => Some(("EADDRNOTAVAIL", "Can't assign requested address")),
50 => Some(("ENETDOWN", "Network is down")),
51 => Some(("ENETUNREACH", "Network is unreachable")),
52 => Some(("ENETRESET", "Network dropped connection on reset")),
53 => Some(("ECONNABORTED", "Software caused connection abort")),
54 => Some(("ECONNRESET", "Connection reset by peer")),
55 => Some(("ENOBUFS", "No buffer space available")),
56 => Some(("EISCONN", "Socket is already connected")),
57 => Some(("ENOTCONN", "Socket is not connected")),
58 => Some(("ESHUTDOWN", "Can't send after socket shutdown")),
59 => Some(("ETOOMANYREFS", "Too many references: can't splice")),
60 => Some(("ETIMEDOUT", "Operation timed out")),
61 => Some(("ECONNREFUSED", "Connection refused")),
62 => Some(("ELOOP", "Too many levels of symbolic links")),
63 => Some(("ENAMETOOLONG", "File name too long")),
64 => Some(("EHOSTDOWN", "Host is down")),
65 => Some(("EHOSTUNREACH", "No route to host")),
66 => Some(("ENOTEMPTY", "Directory not empty")),
67 => Some(("EPROCLIM", "Too many processes")),
68 => Some(("EUSERS", "Too many users")),
69 => Some(("EDQUOT", "Disc quota exceeded")),
70 => Some(("ESTALE", "Stale NFS file handle")),
71 => Some(("EREMOTE", "Too many levels of remote in path")),
72 => Some(("EBADRPC", "RPC struct is bad")),
73 => Some(("ERPCMISMATCH", "RPC version wrong")),
74 => Some(("EPROGUNAVAIL", "RPC prog. not avail")),
75 => Some(("EPROGMISMATCH", "Program version wrong")),
76 => Some(("EPROCUNAVAIL", "Bad procedure for program")),
77 => Some(("ENOLCK", "No locks available")),
78 => Some(("ENOSYS", "Function not implemented")),
79 => Some(("EFTYPE", "Inappropriate file type or format")),
80 => Some(("EAUTH", "Authentication error")),
81 => Some(("ENEEDAUTH", "Need authenticator")),
82 => Some(("EIDRM", "Identifier removed")),
83 => Some(("ENOMSG", "No message of desired type")),
84 => Some(("EOVERFLOW", "Value too large to be stored in data type")),
85 => Some(("ECANCELED", "Operation canceled")),
86 => Some(("EILSEQ", "Illegal byte sequence")),
87 => Some(("ENOATTR", "Attribute not found")),
88 => Some(("EDOOFUS", "Programming error")),
89 => Some(("EBADMSG", "Bad message")),
90 => Some(("EMULTIHOP", "Multihop attempted")),
91 => Some(("ENOLINK", "Link has been severed")),
92 => Some(("EPROTO", "Protocol error")),
93 => Some(("ENOTCAPABLE", "Capabilities insufficient")),
94 => Some(("ECAPMODE", "Not permitted in capability mode")),
95 => Some(("ENOTRECOVERABLE", "State not recoverable")),
96 => Some(("EOWNERDEAD", "Previous owner died")),
97 => Some(("EINTEGRITY", "Integrity check failed")),
_ => None,
}
}
}