2004-11-03 13:51:07 +00:00
|
|
|
.\" Copyright (c) 1996 Andries Brouwer (aeb@cwi.nl)
|
|
|
|
.\"
|
|
|
|
.\" This is free documentation; you can redistribute it and/or
|
|
|
|
.\" modify it under the terms of the GNU General Public License as
|
|
|
|
.\" published by the Free Software Foundation; either version 2 of
|
|
|
|
.\" the License, or (at your option) any later version.
|
|
|
|
.\"
|
|
|
|
.\" The GNU General Public License's references to "object code"
|
|
|
|
.\" and "executables" are to be interpreted as the output of any
|
|
|
|
.\" document formatting or typesetting system, including
|
|
|
|
.\" intermediate and printed output.
|
|
|
|
.\"
|
|
|
|
.\" This manual is distributed in the hope that it will be useful,
|
|
|
|
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
.\" GNU General Public License for more details.
|
|
|
|
.\"
|
|
|
|
.\" You should have received a copy of the GNU General Public
|
|
|
|
.\" License along with this manual; if not, write to the Free
|
|
|
|
.\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
|
|
|
|
.\" USA.
|
|
|
|
.\"
|
2004-11-03 14:43:40 +00:00
|
|
|
.\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
|
2006-08-03 13:57:30 +00:00
|
|
|
.\" Updated for POSIX.1 2001
|
2004-12-17 12:20:07 +00:00
|
|
|
.\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
|
|
|
|
.\" Removed errno declaration prototype, added notes
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.\" 2006-02-09 Kurt Wall, mtk
|
|
|
|
.\" Added non-POSIX errors
|
2004-11-03 13:51:07 +00:00
|
|
|
.\"
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.TH ERRNO 3 2006-02-09 "" "Library functions"
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH NAME
|
|
|
|
errno \- number of last error
|
|
|
|
.SH SYNOPSIS
|
|
|
|
.B #include <errno.h>
|
2004-12-17 12:20:07 +00:00
|
|
|
.\".sp
|
|
|
|
.\".BI "extern int " errno ;
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH DESCRIPTION
|
2007-04-12 22:42:49 +00:00
|
|
|
The
|
2004-12-17 12:20:07 +00:00
|
|
|
.I <errno.h>
|
|
|
|
header file defines the integer variable
|
2005-07-19 15:38:39 +00:00
|
|
|
.BR errno ,
|
2004-12-17 12:20:07 +00:00
|
|
|
which is set by system calls and some library functions in the event
|
|
|
|
of an error to indicate what went wrong.
|
|
|
|
Its value is significant only when the call
|
|
|
|
returned an error (usually \-1), and a function that does succeed
|
2004-11-03 13:51:07 +00:00
|
|
|
is allowed to change
|
|
|
|
.BR errno .
|
|
|
|
|
2004-12-17 12:20:07 +00:00
|
|
|
Sometimes, when \-1 is also a valid successful return value
|
|
|
|
one has to zero
|
2004-11-03 13:51:07 +00:00
|
|
|
.B errno
|
|
|
|
before the call in order to detect possible errors.
|
|
|
|
|
|
|
|
\fBerrno\fR is defined by the ISO C standard to be a modifiable lvalue
|
2006-02-09 20:24:53 +00:00
|
|
|
of type \fIint\fR, and must not be explicitly declared; \fBerrno\fR
|
2004-11-03 13:51:07 +00:00
|
|
|
may be a macro. \fBerrno\fR is thread-local; setting it in one thread
|
|
|
|
does not affect its value in any other thread.
|
|
|
|
|
|
|
|
Valid error numbers are all non-zero; \fBerrno\fR is never set to zero
|
2007-04-12 22:42:49 +00:00
|
|
|
by any library function.
|
|
|
|
All the error names specified by POSIX.1
|
2004-12-17 12:20:07 +00:00
|
|
|
must have distinct values, with the exception of
|
|
|
|
.B EAGAIN
|
2007-04-12 22:42:49 +00:00
|
|
|
and
|
2004-12-17 12:20:07 +00:00
|
|
|
.BR EWOULDBLOCK ,
|
|
|
|
which may be the same.
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2007-04-12 22:42:49 +00:00
|
|
|
.\" The following is now
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.\" POSIX.1 (2001 edition) lists the following symbolic error names. Of
|
|
|
|
.\" these, \fBEDOM\fR and \fBERANGE\fR are in the ISO C standard. ISO C
|
|
|
|
.\" Amendment 1 defines the additional error number \fBEILSEQ\fR for
|
|
|
|
.\" coding errors in multibyte or wide characters.
|
2007-04-12 22:42:49 +00:00
|
|
|
.\"
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
Below is a list of the symbolic error names that are defined on Linux.
|
|
|
|
Some of these are marked
|
|
|
|
.IR POSIX.1 ,
|
|
|
|
indicating that the name is defined by POSIX.1-2001, or
|
|
|
|
.IR C99 ,
|
|
|
|
indicating that the name is defined by C99.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR E2BIG
|
|
|
|
Argument list too long (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EACCES
|
|
|
|
Permission denied (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EADDRINUSE
|
|
|
|
Address already in use (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EADDRNOTAVAIL
|
|
|
|
Address not available (POSIX.1)
|
|
|
|
.\" EADV is only an error on HURD(?)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EAFNOSUPPORT
|
|
|
|
Address family not supported (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EAGAIN
|
2007-04-12 22:42:49 +00:00
|
|
|
Resource temporarily unavailable (may be the same value as
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EWOULDBLOCK )
|
|
|
|
(POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EALREADY
|
|
|
|
Connection already in progress (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EBADE
|
|
|
|
Invalid exchange
|
|
|
|
.TP
|
|
|
|
.BR EBADF
|
|
|
|
Bad file descriptor (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EBADFD
|
|
|
|
File descriptor in bad state
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EBADMSG
|
|
|
|
Bad message (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EBADR
|
|
|
|
Invalid request descriptor
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EBADRQC
|
|
|
|
Invalid request code
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EBADSLT
|
|
|
|
Invalid slot
|
|
|
|
.\" EBFONT is defined but appears not to be used by kernel or glibc.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EBUSY
|
|
|
|
Device or resource busy (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ECANCELED
|
|
|
|
Operation canceled (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ECHILD
|
|
|
|
No child processes (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B ECHRNG
|
|
|
|
Channel number out of range
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B ECOMM
|
|
|
|
Communication error on send
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ECONNABORTED
|
|
|
|
Connection aborted (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR ECONNREFUSED
|
|
|
|
Connection refused (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR ECONNRESET
|
|
|
|
Connection reset (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EDEADLK
|
|
|
|
Resource deadlock avoided (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EDEADLOCK
|
|
|
|
Synonym for
|
2004-11-03 13:51:07 +00:00
|
|
|
.B EDEADLK
|
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EDESTADDRREQ
|
|
|
|
Destination address required (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EDOM
|
|
|
|
Mathematics argument out of domain of function (POSIX.1, C99)
|
|
|
|
.\" EDOTDOT is defined but appears to be unused
|
|
|
|
.TP
|
|
|
|
.BR EDQUOT
|
|
|
|
.\" POSIX just says "Reserved"
|
|
|
|
Disk quota exceeded (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EEXIST
|
|
|
|
File exists (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EFAULT
|
|
|
|
Bad address (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EFBIG
|
|
|
|
File too large (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EHOSTDOWN
|
|
|
|
Host is down
|
|
|
|
.TP
|
|
|
|
.BR EHOSTUNREACH
|
|
|
|
Host is unreachable (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EIDRM
|
|
|
|
Identifier removed (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EILSEQ
|
|
|
|
Illegal byte sequence (POSIX.1, C99)
|
|
|
|
.TP
|
|
|
|
.BR EINPROGRESS
|
|
|
|
Operation in progress (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EINTR
|
|
|
|
Interrupted function call (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EINVAL
|
|
|
|
Invalid argument (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EIO
|
|
|
|
Input/output error (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EISCONN
|
|
|
|
Socket is connected (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EISDIR
|
|
|
|
Is a directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EISNAM
|
|
|
|
Is a named type file
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EKEYEXPIRED
|
|
|
|
Key has expired
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EKEYREJECTED
|
|
|
|
Key was rejected by service
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EKEYREVOKED
|
|
|
|
Key has been revoked
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B EL2HLT
|
|
|
|
Level 2 halted
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B EL2NSYNC
|
|
|
|
Level 2 not synchronized
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B EL3HLT
|
|
|
|
Level 3 halted
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B EL3RST
|
|
|
|
Level 3 halted
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELIBACC
|
|
|
|
Cannot access a needed shared library
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELIBBAD
|
|
|
|
Accessing a corrupted shared library
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELIBMAX
|
|
|
|
Attempting to link in too many shared libraries
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELIBSCN
|
|
|
|
lib section in a.out corrupted
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELIBEXEC
|
|
|
|
Cannot exec a shared library directly
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ELOOP
|
|
|
|
Too many levels of symbolic links (POSIX.1)
|
|
|
|
.\" ELNRNG is defined but appears to be unused
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EMEDIUMTYPE
|
|
|
|
Wrong medium type
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EMFILE
|
|
|
|
Too many open files (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EMLINK
|
|
|
|
Too many links (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EMSGSIZE
|
|
|
|
Message too long (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EMULTIHOP
|
|
|
|
.\" POSIX says "Reserved"
|
|
|
|
Multihop attempted (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENAMETOOLONG
|
|
|
|
Filename too long (POSIX.1)
|
|
|
|
.\" ENAVAIL is defined, but appears not to be used
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENETDOWN
|
|
|
|
Network is down (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENETRESET
|
|
|
|
Connection aborted by network (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENETUNREACH
|
|
|
|
Network unreachable (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENFILE
|
|
|
|
Too many open files in system (POSIX.1)
|
|
|
|
.\" ENOANO is defined but appears to be unused.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOBUFS
|
|
|
|
No buffer space available (POSIX.1 (XSI STREAMS option))
|
|
|
|
.\" ENOCSI is defined but appears to be unused.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENODATA
|
|
|
|
No message is available on the STREAM head read queue (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENODEV
|
|
|
|
No such device (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOENT
|
|
|
|
No such file or directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOEXEC
|
|
|
|
Exec format error (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOKEY
|
2006-05-29 01:20:08 +00:00
|
|
|
Required key not available
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOLCK
|
|
|
|
No locks available (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOLINK
|
|
|
|
.\" POSIX says "Reserved"
|
|
|
|
Link has been severed (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOMEDIUM
|
|
|
|
No medium found
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOMEM
|
|
|
|
Not enough space (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOMSG
|
|
|
|
No message of the desired type (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENONET
|
|
|
|
Machine is not on the network
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOPKG
|
|
|
|
Package not installed
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOPROTOOPT
|
|
|
|
Protocol not available (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOSPC
|
|
|
|
No space left on device (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOSR
|
|
|
|
No STREAM resources (POSIX.1 (XSI STREAMS option))
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-04-12 22:42:49 +00:00
|
|
|
.BR ENOSTR
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
Not a STREAM (POSIX.1 (XSI STREAMS option))
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOSYS
|
|
|
|
Function not implemented (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTBLK
|
|
|
|
Block device required
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTCONN
|
|
|
|
The socket is not connected (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTDIR
|
|
|
|
Not a directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTEMPTY
|
|
|
|
Directory not empty (POSIX.1)
|
|
|
|
.\" ENOTNAM is defined but appears to be unused.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTSOCK
|
|
|
|
Not a socket (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTSUP
|
|
|
|
Operation not supported (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTTY
|
|
|
|
Inappropriate I/O control operation (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENOTUNIQ
|
|
|
|
Name not unique on network
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR ENXIO
|
|
|
|
No such device or address (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EOPNOTSUPP
|
|
|
|
Operation not supported on socket (POSIX.1)
|
|
|
|
.sp
|
|
|
|
(ENOTSUP and EOPNOTSUPP have the same value on Linux, but
|
|
|
|
according to POSIX.1 these error values should be distinct.)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EOVERFLOW
|
|
|
|
Value too large to be stored in data type (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EPERM
|
|
|
|
Operation not permitted (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EPFNOSUPPORT
|
|
|
|
Protocol family not supported
|
|
|
|
.TP
|
|
|
|
.BR EPIPE
|
|
|
|
Broken pipe (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EPROTO
|
|
|
|
Protocol error (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EPROTONOSUPPORT
|
|
|
|
Protocol not supported (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EPROTOTYPE
|
|
|
|
Protocol wrong type for socket (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR ERANGE
|
|
|
|
Result too large (POSIX.1, C99)
|
|
|
|
.TP
|
|
|
|
.BR EREMCHG
|
|
|
|
Remote address changed
|
|
|
|
.TP
|
|
|
|
.BR EREMOTE
|
|
|
|
Object is remote
|
|
|
|
.TP
|
|
|
|
.BR EREMOTEIO
|
|
|
|
Remote I/O error
|
|
|
|
.TP
|
|
|
|
.BR ERESTART
|
|
|
|
Interrupted system call should be restarted
|
|
|
|
.TP
|
|
|
|
.BR EROFS
|
|
|
|
Read-only file system (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR ESHUTDOWN
|
|
|
|
Cannot send after transport endpoint shutdown
|
|
|
|
.TP
|
|
|
|
.BR ESPIPE
|
|
|
|
Invalid seek (POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR ESOCKTNOSUPPORT
|
|
|
|
Socket type not supported
|
|
|
|
.TP
|
|
|
|
.BR ESRCH
|
|
|
|
No such process (POSIX.1)
|
|
|
|
.\" ESRMNT is defined but appears not to be used
|
|
|
|
.TP
|
|
|
|
.BR ESTALE
|
2006-12-27 03:59:48 +00:00
|
|
|
Stale file handle (POSIX.1)
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.sp
|
|
|
|
This error can occur for NFS and for other file systems
|
|
|
|
.TP
|
|
|
|
.BR ESTRPIPE
|
|
|
|
Streams pipe error
|
|
|
|
.TP
|
|
|
|
.BR ETIME
|
|
|
|
Timer expired
|
|
|
|
(POSIX.1 (XSI STREAMS option))
|
|
|
|
.sp
|
2007-04-12 22:42:49 +00:00
|
|
|
(POSIX.1 says "STREAM
|
|
|
|
.BR ioctl ()
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
timeout")
|
|
|
|
.TP
|
|
|
|
.BR ETIMEDOUT
|
|
|
|
Connection timed out (POSIX.1)
|
|
|
|
.\" ETOOMANYREFS is defined, but appears not to be used.
|
|
|
|
.TP
|
|
|
|
.BR ETXTBSY
|
|
|
|
Text file busy (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EUCLEAN
|
2006-03-20 03:13:48 +00:00
|
|
|
Structure needs cleaning
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EUNATCH
|
|
|
|
Protocol driver not attached
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.BR EUSERS
|
|
|
|
Too many users
|
|
|
|
.TP
|
|
|
|
.BR EWOULDBLOCK
|
2004-11-03 13:51:07 +00:00
|
|
|
Operation would block (may be same value as
|
2007-04-12 22:42:49 +00:00
|
|
|
.BR EAGAIN )
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
(POSIX.1)
|
|
|
|
.TP
|
|
|
|
.BR EXDEV
|
|
|
|
Improper link (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
Add Linux-specific errors, and mark individual errors as being present
in POSIX or C99
Hello Kurt,
Thanks for your message.
> man3/errno.3 was missing some errors.
Indeed.
> This patch updates errno.3 based
> on /usr/include/linux/errno.h as of 2.6.16-rc2.
I do not quite understand that last: /usr/include/linux/errno.h is a
userland file -- it probably won't tie up too well to a
specific kernel version (or am I missing something?).
> I also synced the error
> description in the man page with the error descriptions from the header
> file.
This generates some useful info, but also some things that are incorrect.
For example, since you are talking about a glibc header, does a
particular error even occur on Linux. (See some examples below.)
I think you also overlooked the fact that the page says that the listed
errors are defined by POSIX.1-2001. So it is not sufficient to just
add new errors to the list. On the other hand, it is irritating
that the current page does not list Linux-specific errors.
And you patch has finally pushed me to do something I've been
thinking of for a while. So I've changed the page to mark the
errors that are POSIX, and added the Linux-specifc errors,
integrating some of your patch.
> The patch was diffed against manpages-2.22.
Thanks -- many people forget to mention that detail.
> --- errno.3.orig 2005-12-14 07:09:39.000000000 -0500
> +++ errno.3 2006-02-06 23:45:52.000000000 -0500
> @@ -23,9 +23,11 @@
> .\" 5 Oct 2002, Modified by Michael Kerrisk <mtk-manpages@gmx.net>
> .\" Updated for POSIX 1003.1 2001
> .\" 2004-12-17 Martin Schulze <joey@infodrom.org>, mtk
> -.\" Removed errno declaration prototype, added notes
> +.\" Removed errno declaration prototype, added notes
> +.\" 7 Feb 2006, Modified by Kurt Wall <kwall@kurtwerks.com>
> +.\" Add missing errors, sync to linux-2.6.16-rc2
> .\"
> -.TH ERRNO 3 2004-12-17 "" "Library functions"
> +.TH ERRNO 3 2006-02-07 "" "Library functions"
> .SH NAME
> errno \- number of last error
> .SH SYNOPSIS
> @@ -71,61 +73,95 @@
> .\" FIXME The following list is far from complete
> .TP
> .B E2BIG
> -Arg list too long
> +Argument list too long
ok
> .TP
> .B EACCES
> Permission denied
> .TP
> .B EADDRINUSE
> -Address in use
> +Address already in use
ok
> .TP
> .B EADDRNOTAVAIL
> -Address not available
> +Cannot assign requested address
ok
> +.TP
> +.B EADV
> +Advertise error
This is a HURD error. As far as I can tell it does not occur on Linux.
> .TP
> .B EAFNOSUPPORT
> -Address family not supported
> +Address family not supported by protocol
POSIX differs. I stayed with POSIX.
> .TP
> .B EAGAIN
> -Resource temporarily unavailable
> +Try again
This is wrong. (i.e., it does not match POSIX and/or
what perror(3) produces)
> .TP
> .B EALREADY
> -Connection already in progress
> +Operation already in progress
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EBADE
> +Invalid exchange
ok
> .TP
> .B EBADF
> -Bad file descriptor
> +Bad file number
This is wrong.
> +.TP
> +.B EBADFD
> +File descriptor in bad state
ok
> .TP
> .B EBADMSG
> -Bad message
> +Not a data message
This is wrong.
> +.TP
> +.B EBADR
> +Invalid request descriptor
ok
> +.TP
> +.B EBADRQC
> +Invalid request code
ok
> +.TP
> +.B EBADSLT
> +Invalid slot
ok
> +.TP
> +.B EBFONT
> +Bad font file format
As far as I can tell, this is not used on Linux. Let me know
if you find otherwise. (I didn't add it)
> .TP
> .B EBUSY
> -Resource busy
> +Device or resource busy
ok
> .TP
> .B ECANCELED
> -Operation canceled
> +Operation Canceled
Please review the output of automated scripts!
(not changed)
> .TP
> .B ECHILD
> No child processes
> .TP
> +.B ECHRNG
> +Channel number out of range
ok
> +.TP
> +.B ECOMM
> +Communication error on send
ok
> +.TP
> .B ECONNABORTED
> -Connection aborted
> +Software caused connection abort
POSIX differs. I stayed with POSIX.
> .TP
> .B ECONNREFUSED
> Connection refused
> .TP
> .B ECONNRESET
> -Connection reset
> +Connection reset by peer
POSIX differs. I stayed with POSIX.
> .TP
> .B EDEADLK
> -Resource deadlock avoided
> +Resource deadlock would occur
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EDEADLOCK
> +Resource deadlock would occur (might be the same value as
> +.BR EDEADLK)
I wrote just "Synonym for EDEADLK"
> .TP
> .B EDESTADDRREQ
> Destination address required
> .TP
> .B EDOM
> -Domain error
> +Math argument out of domain of func
? Garbled
I wrote the POSIX defn: Mathematics argument out of domain of function
> +.TP
> +.B EDOTDOT
> +RFS specific error
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B EDQUOT
> -Reserved
> +Quota exceeded
POSIX says "Reserved." In this case better to go with
"Disk quota exceeded"
> .TP
> .B EEXIST
> File exists
> @@ -136,8 +172,11 @@
> .B EFBIG
> File too large
> .TP
> +.B EHOSTDOWN
> +Host is down
ok
> +.TP
> .B EHOSTUNREACH
> -Host is unreachable
> +No route to host
POSIX differs. I stayed with POSIX.
> .TP
> .B EIDRM
> Identifier removed
> @@ -146,25 +185,70 @@
> Illegal byte sequence
> .TP
> .B EINPROGRESS
> -Operation in progress
> +Operation now in progress
POSIX differs. I stayed with POSIX.
> .TP
> .B EINTR
> -Interrupted function call
> +Interrupted system call
POSIX differs. I stayed with POSIX.
> .TP
> .B EINVAL
> Invalid argument
> .TP
> .B EIO
> -Input/output error
> +I/O error
POSIX differs. I stayed with POSIX.
> .TP
> .B EISCONN
> -Socket is connected
> +Transport endpoint is already connected
POSIX differs. I stayed with POSIX.
> .TP
> .B EISDIR
> Is a directory
> .TP
> +.B EISNAM
> +Is a named type file
ok
> +.TP
> +.B EKEYEXPIRED
> +Key has expired
ok
> +.TP
> +.B EKEYREJECTED
> +Key was rejected by service
ok
> +.TP
> +.B EKEYREVOKED
> +Key has been revoked
ok
> +.TP
> +.B EL2HLT
> +Level 2 halted
ok
> +.TP
> +.B EL2NSYNC
> +Level 2 not synchronized
ok
> +.TP
> +.B EL3HLT
> +Level 3 halted
ok
> +.TP
> +.B EL3RST
> +Level 3 reset
ok
> +.TP
> +.B ELIBACC
> +Can not access a needed shared library
ok
> +.TP
> +.B ELIBBAD
> +Accessing a corrupted shared library
ok
> +.TP
> +.B ELIBEXEC
> +Cannot exec a shared library directly
ok
> +.TP
> +.B ELIBMAX
> +Attempting to link in too many shared libraries
ok
> +.TP
> +.B ELIBSCN
> +.lib section in a.out corrupted
ok
> +.TP
> +.B ELNRNG
> +Link number out of range
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ELOOP
> -Too many levels of symbolic links
> +Too many symbolic links encountered
this is wrong
> +.TP
> +.B EMEDIUMTYPE
> +Wrong medium type
> .TP
> .B EMFILE
> Too many open files
> @@ -173,32 +257,41 @@
> Too many links
> .TP
> .B EMSGSIZE
> -Inappropriate message buffer length
> +Message too long
ok
> .TP
> .B EMULTIHOP
> -Reserved
> +Multihop attempted
ok
POSIX says "Reserved." In this case better to go with
Linux.
> .TP
> .B ENAMETOOLONG
> -Filename too long
> +File name too long
Scripted output?
(no change)
> +.TP
> +.B ENAVAIL
> +No XENIX semaphores available
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENETDOWN
> Network is down
> .TP
> .B ENETRESET
> -Connection aborted by network
> +Network dropped connection because of reset
POSIX differs. I stayed with POSIX.
> .TP
> .B ENETUNREACH
> -Network unreachable
> +Network is unreachable
POSIX differs. I stayed with POSIX.
> .TP
> .B ENFILE
> -Too many open files in system
> +File table overflow
This is wrong
> +.TP
> +.B ENOANO
> +No anode
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ENOBUFS
> No buffer space available
> +.TP
> +.B ENOCSI
> +No CSI structure available
This is defined, but appears not to be used.
(I didn't add it)
> .\" ENODATA is part of XSR option
> .TP
> .B ENODATA
> -No message is available on the STREAM head read queue
> +No data available
POSIX differs. I stayed with POSIX.
> .TP
> .B ENODEV
> No such device
> @@ -209,17 +302,29 @@
> .B ENOEXEC
> Exec format error
> .TP
> +.B ENOKEY
> +Required key not available
ok
> +.TP
> .B ENOLCK
> -No locks available
> +No record locks available
This is wrong
> .TP
> .B ENOLINK
> -Reserved
> +Link has been severed
ok
POSIX says "Reserved." In this case better to go with
Linux.
> +.TP
> +.B ENOMEDIUM
> +No medium found
ok
> .TP
> .B ENOMEM
> -Not enough space
> +Out of memory
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOMSG
> -No message of the desired type
> +No message of desired type
POSIX differs. I stayed with POSIX.
> +.TP
> +.B ENONET
> +Machine is not on the network
ok
> +.TP
> +.B ENOPKG
> +Package not installed
ok
> .TP
> .B ENOPROTOOPT
> Protocol not available
> @@ -229,17 +334,20 @@
> .\" ENOSR is part of XSR option
> .TP
> .B ENOSR
> -No STREAM resources
> +Out of streams resources
POSIX differs. I stayed with POSIX.
> .\" ENOSTR is part of XSR option
> .TP
> .B ENOSTR
> -Not a STREAM
> +Device not a stream
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOSYS
> Function not implemented
> .TP
> +.B ENOTBLK
> +Block device required
> +.TP
ok
> .B ENOTCONN
> -The socket is not connected
> +Transport endpoint is not connected
POSIX differs. I stayed with POSIX.
> .TP
> .B ENOTDIR
> Not a directory
> @@ -247,27 +355,33 @@
> .B ENOTEMPTY
> Directory not empty
> .TP
> -.B ENOTSOCK
> -Not a socket
> +.B ENOTNAM
> +Not a XENIX named type file
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> -.B ENOTSUP
> -Not supported
No! This exists.
> +.B ENOTSOCK
> +Socket operation on non-socket
> .TP
> .B ENOTTY
> -Inappropriate I/O control operation
> +Not a typewriter
this is wrong
> +.TP
> +.B ENOTUNIQ
> +Name not unique on network
ok
> .TP
> .B ENXIO
> No such device or address
> .TP
> .B EOPNOTSUPP
> -Operation not supported on socket
> +Operation not supported on transport endpoint
POSIX differs. I stayed with POSIX.
(In passing ENOTSUP and EOPNOTSUPP have the same value on Linux;
POSIX.1 does not permit this.)
> .TP
> .B EOVERFLOW
> -Value too large to be stored in data type
> +Value too large for defined data type
POSIX differs. I stayed with POSIX.
> .TP
> .B EPERM
> Operation not permitted
> .TP
> +.B EPFNOSUPPORT
> +Protocol family not supported
ok
> +.TP
> .B EPIPE
> Broken pipe
> .TP
> @@ -281,39 +395,76 @@
> Protocol wrong type for socket
> .TP
> .B ERANGE
> -Result too large
> +Math result not representable
POSIX differs. I stayed with POSIX.
> +.TP
> +.B EREMCHG
> +Remote address changed
ok
> +.TP
> +.B EREMOTE
> +Object is remote
ok
> +.TP
> +.B EREMOTEIO
> +Remote I/O error
ok
> +.TP
> +.B ERESTART
> +Interrupted system call should be restarted
ok
> .TP
> .B EROFS
> Read-only file system
> .TP
> +.B ESHUTDOWN
> +Cannot send after transport endpoint shutdown
ok
> +.TP
> +.B ESOCKTNOSUPPORT
> +Socket type not supported
ok
> +.TP
> .B ESPIPE
> -Invalid seek
> +Illegal seek
POSIX differs. I stayed with POSIX.
> .TP
> .B ESRCH
> No such process
> .TP
> +.B ESRMNT
> +Srmount error
This is defined, but appears not to be used.
(I didn't add it)
> +.TP
> .B ESTALE
> -Stale file handle
> +Stale NFS file handle
Tricky -- you are right about the error message,
but the message itself is wrong, because the error
can occur on other file sytems also.
(not changed)
> .\" Can occur for NFS and for other file systems
> .\" ETIME is part of XSR option
> .TP
> +.B ESTRPIPE
> +Streams pipe error
ok
> +.TP
> .B ETIME
> -STREAM
> -.BR ioctl ()
> -timeout
> +Timer expired
POSIX differs, but Linux doesn't have streams, and the error is
used for various purposes. Changed as you proposed.
> .TP
> .B ETIMEDOUT
> -Operation timed out
> +Connection timed out
ok
> +.TP
> +.B ETOOMANYREFS
> +Too many references: cannot splice
This is defined, but appears not to be used.
(I didn't add it)
> .TP
> .B ETXTBSY
> Text file busy
> .TP
> -.B EWOULDBLOCK
> -Operation would block (may be same value as
> -.BR EAGAIN )
Absolutely not!!
> +.B EUCLEAN
> +Structure needs cleaning
ok
> +.TP
> +.B EUNATCH
> +Protocol driver not attached
ok
> +.TP
> +.B EUSERS
> +Too many users
ok
> +.TP
> +.B EWOULDBLOCK
> +Operation would block (might be same value as
> +.BR EAGAIN)
okay (except formatting was not quite right: .BR EAGAIN )
> .TP
> .B EXDEV
> -Improper link
> +Cross-device link
> +.TP
> +.B EXFULL
> +Exchange full
ok
2006-02-08 18:26:38 +00:00
|
|
|
.B EXFULL
|
|
|
|
Exchange full
|
2004-12-17 12:20:07 +00:00
|
|
|
.SH NOTES
|
2004-11-03 13:51:07 +00:00
|
|
|
A common mistake is to do
|
|
|
|
.RS
|
|
|
|
.nf
|
|
|
|
|
2005-07-06 12:57:38 +00:00
|
|
|
if (somecall() == \-1) {
|
2004-11-03 13:51:07 +00:00
|
|
|
printf("somecall() failed\en");
|
|
|
|
if (errno == ...) { ... }
|
|
|
|
}
|
|
|
|
|
|
|
|
.fi
|
|
|
|
.RE
|
|
|
|
where
|
|
|
|
.I errno
|
|
|
|
no longer needs to have the value it had upon return from
|
2005-10-19 07:07:02 +00:00
|
|
|
.IR somecall ()
|
2004-12-17 12:20:07 +00:00
|
|
|
(i.e., it may have been changed by the
|
2005-11-02 11:34:24 +00:00
|
|
|
.BR printf ()).
|
2004-11-03 13:51:07 +00:00
|
|
|
If the value of
|
|
|
|
.I errno
|
|
|
|
should be preserved across a library call, it must be saved:
|
|
|
|
.RS
|
|
|
|
.nf
|
|
|
|
|
2005-07-06 12:57:38 +00:00
|
|
|
if (somecall() == \-1) {
|
2004-11-03 13:51:07 +00:00
|
|
|
int errsv = errno;
|
|
|
|
printf("somecall() failed\en");
|
|
|
|
if (errsv == ...) { ... }
|
|
|
|
}
|
|
|
|
.fi
|
|
|
|
.RE
|
2004-12-17 12:20:07 +00:00
|
|
|
.PP
|
|
|
|
It was common in traditional C to declare
|
|
|
|
.I errno
|
|
|
|
manually
|
2007-04-12 22:42:49 +00:00
|
|
|
(i.e.,
|
2004-12-17 12:20:07 +00:00
|
|
|
.IR "extern int errno" )
|
|
|
|
instead of including
|
|
|
|
.IR <errno.h> .
|
|
|
|
.BR "Do not do this" .
|
|
|
|
It will not work with modern versions of the C library.
|
|
|
|
However, on (very) old Unix systems, there may be no
|
|
|
|
.I <errno.h>
|
|
|
|
and the declaration is needed.
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH "SEE ALSO"
|
2005-12-14 12:09:39 +00:00
|
|
|
.BR err (3),
|
2006-04-28 06:47:38 +00:00
|
|
|
.BR error (3),
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR perror (3),
|
|
|
|
.BR strerror (3)
|