]> git.lizzy.rs Git - rust.git/blobdiff - library/std/src/sys/unix/mod.rs
Rename ErrorKind::Unknown to Uncategorized.
[rust.git] / library / std / src / sys / unix / mod.rs
index 6c4fbaf27344b8bd3581a6565b782d0e2f91dfd3..21c718825b889c6081a8934068460dc990ad01c8 100644 (file)
@@ -15,7 +15,6 @@
 pub mod cmath;
 pub mod condvar;
 pub mod env;
-pub mod ext;
 pub mod fd;
 pub mod fs;
 pub mod futex;
@@ -149,13 +148,14 @@ pub fn decode_error_kind(errno: i32) -> ErrorKind {
         libc::ETIMEDOUT => ErrorKind::TimedOut,
         libc::EEXIST => ErrorKind::AlreadyExists,
         libc::ENOSYS => ErrorKind::Unsupported,
+        libc::ENOMEM => ErrorKind::OutOfMemory,
 
         // These two constants can have the same value on some systems,
         // but different values on others, so we can't use a match
         // clause
         x if x == libc::EAGAIN || x == libc::EWOULDBLOCK => ErrorKind::WouldBlock,
 
-        _ => ErrorKind::Other,
+        _ => ErrorKind::Uncategorized,
     }
 }