Skip to content

Commit 698d397

Browse files
committed
Auto merge of #2466 - atopia:master, r=JohnTitor
add more errno constants to uclibc Add more errno constants as requested by rustc since commit 1ec9454403e9bb0361d0725524c4bd27030474cc (for a discussion of the change, see rust-lang/rust#79965). The constant values and descriptions were taken from include/uapi/asm-generic/errno.h in the Linux kernel, since "uClibc will be compiled to match the interfaces available in the provided version of the Linux kernel headers". While the fork of uClibc in L4Re nominally has its own errno constants, they appear to be based on the Linux header file and thus are the same.
2 parents 6492988 + 08315ab commit 698d397

File tree

1 file changed

+8
-0
lines changed
  • src/unix/linux_like/linux/uclibc/x86_64

1 file changed

+8
-0
lines changed

src/unix/linux_like/linux/uclibc/x86_64/mod.rs

+8
Original file line numberDiff line numberDiff line change
@@ -292,15 +292,23 @@ s_no_extra_traits! {
292292
}
293293

294294
// constants
295+
pub const ENAMETOOLONG: ::c_int = 36; // File name too long
296+
pub const ENOTEMPTY: ::c_int = 39; // Directory not empty
297+
pub const ELOOP: ::c_int = 40; // Too many symbolic links encountered
295298
pub const EADDRINUSE: ::c_int = 98; // Address already in use
296299
pub const EADDRNOTAVAIL: ::c_int = 99; // Cannot assign requested address
300+
pub const ENETDOWN: ::c_int = 100; // Network is down
301+
pub const ENETUNREACH: ::c_int = 101; // Network is unreachable
297302
pub const ECONNABORTED: ::c_int = 103; // Software caused connection abort
298303
pub const ECONNREFUSED: ::c_int = 111; // Connection refused
299304
pub const ECONNRESET: ::c_int = 104; // Connection reset by peer
300305
pub const EDEADLK: ::c_int = 35; // Resource deadlock would occur
301306
pub const ENOSYS: ::c_int = 38; // Function not implemented
302307
pub const ENOTCONN: ::c_int = 107; // Transport endpoint is not connected
303308
pub const ETIMEDOUT: ::c_int = 110; // connection timed out
309+
pub const ESTALE: ::c_int = 116; // Stale file handle
310+
pub const EHOSTUNREACH: ::c_int = 113; // No route to host
311+
pub const EDQUOT: ::c_int = 122; // Quota exceeded
304312
pub const EOPNOTSUPP: ::c_int = 0x5f;
305313
pub const ENODATA: ::c_int = 0x3d;
306314
pub const O_APPEND: ::c_int = 02000;

0 commit comments

Comments
 (0)