Crate posix_errors[][src]

Posix error codes and handy functions for using them.

Error codes taken from http://fxr.watson.org/fxr/source/sys/errno.h

Structs

PosixError

Struct containing a posix error code and an error message

Constants

E2BIG

Argument list too long

EACCES

Permission denied

EADDRINUSE

Address already in use

EADDRNOTAVAIL

Can’t assign requested address

EAFNOSUPPORT

Address family not supported by protocol family

EAGAIN

Resource temporarily unavailable

EALREADY

Operation already in progress

EAUTH

Authentication error

EBADF

Bad file descriptor

EBADMSG

Bad message

EBADRPC

RPC struct is bad

EBUSY

Device busy

ECANCELED

Operation canceled

ECAPMODE

Not permitted in capability mode

ECHILD

No child processes

ECONNABORTED

Software caused connection abort

ECONNREFUSED

Connection refused

ECONNRESET

Connection reset by peer

EDEADLK

Resource deadlock avoided

EDESTADDRREQ

Destination address required

EDOM

Numerical argument out of domain

EDOOFUS

Programming error

EDQUOT

Disc quota exceeded

EEXIST

File exists

EFAULT

Bad address

EFBIG

File too large

EFTYPE

Inappropriate file type or format

EHOSTDOWN

Host is down

EHOSTUNREACH

No route to host

EIDRM

Identifier removed

EILSEQ

Illegal byte sequence

EINPROGRESS

Operation now in progress

EINTR

Interrupted system call

EINVAL

Invalid argument

EIO

Input/utput error

EISCONN

Socket is already connected

EISDIR

Is a directory

ELAST

Must be equal largest errno

ELOOP

Too many levels of symbolic links

EMFILE

Too many open files

EMLINK

Too many links

EMSGSIZE

Message too long

EMULTIHOP

Multihop attempted

ENAMETOOLONG

File name too long

ENEEDAUTH

Need authenticator

ENETDOWN

Network is down

ENETRESET

Network dropped connection on reset

ENETUNREACH

Network is unreachable

ENFILE

Too many open files in system

ENOATTR

Attribute not found

ENOBUFS

No buffer space available

ENODEV

Operation not supported by device

ENOENT

No such file or directory

ENOEXEC

Exec format error

ENOLCK

No locks available

ENOLINK

Link has been severed

ENOMEM

Cannot allocate memory

ENOMSG

No message of desired type

ENOPROTOOPT

Protocol not available

ENOSPC

No space left on device

ENOSYS

Function not implemented

ENOTBLK

Block device required

ENOTCAPABLE

Capabilities insufficient

ENOTCONN

Socket is not connected

ENOTDIR

Not a directory

ENOTEMPTY

Directory not empty

ENOTRECOVERABLE

State not recoverable

ENOTSOCK

Socket operation on non-socket

ENOTSUP

Operation not supported

ENOTTY

Inappropriate ioctl for device

ENXIO

Device not configured

EOPNOTSUPP

Operation not supported

EOVERFLOW

Value too large to be stored in data type

EOWNERDEAD

Previous owner died

EPERM

Operation not permitted

EPFNOSUPPORT

Protocol family not supported

EPIPE

Broken pipe

EPROCLIM

Too many processes

EPROCUNAVAIL

Bad procedure for program

EPROGMISMATCH

Program version wrong

EPROGUNAVAIL

RPC prog. not avail

EPROTO

Protocol error

EPROTONOSUPPORT

Protocol not supported

EPROTOTYPE

Protocol wrong type for socket

ERANGE

Result too large

EREMOTE

Too many levels of remote in path

EROFS

Read-only filesystem

ERPCMISMATCH

RPC version wrong

ESHUTDOWN

Can’t send after socket shutdown

ESOCKTNOSUPPORT

Socket type not supported

ESPIPE

Illegal seek

ESRCH

No such process

ESTALE

Stale NFS file handle

ETIMEDOUT

Operation timed out

ETOOMANYREFS

Too many references: can’t splice

ETXTBSY

Text file busy

EUSERS

Too many users

EWOULDBLOCK

Resource temporarily unavailable

EXDEV

Cross-device link

Functions

error_from_outputDeprecated

Return a PosixError from a failed std::process::Output

to_posix_errorDeprecated

Convert std::io::Error to a PosixError