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.
|
|
|
|
.\"
|
2007-09-20 06:52:22 +00:00
|
|
|
.\" 5 Oct 2002, Modified by Michael Kerrisk <mtk.manpages@gmail.com>
|
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
|
|
|
.\"
|
2008-07-08 12:32:50 +00:00
|
|
|
.TH ERRNO 3 2008-07-09 "" "Linux Programmer's Manual"
|
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
|
2007-06-22 06:05:43 +00:00
|
|
|
.IR 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.
|
2008-07-08 12:32:50 +00:00
|
|
|
Its value is significant only when the return value of
|
|
|
|
the call indicated an error
|
|
|
|
(i.e., \-1 from most system calls;
|
|
|
|
\-1 or NULL from most library functions);
|
|
|
|
a function that succeeds
|
|
|
|
.I is
|
|
|
|
allowed to change
|
2007-06-22 06:05:43 +00:00
|
|
|
.IR errno .
|
2004-11-03 13:51:07 +00:00
|
|
|
|
intro.1, time.1, adjtimex.2, capget.2, eventfd.2, fcntl.2, getrlimit.2, getsockopt.2, gettimeofday.2, intro.2, ioctl_list.2, ioperm.2, mlock.2, pivot_root.2, poll.2, prctl.2, ptrace.2, sched_setscheduler.2, select_tut.2, semget.2, sigaltstack.2, signalfd.2, sysctl.2, timer_settime.2, timerfd_create.2, wait.2, CPU_SET.3, argz_add.3, assert_perror.3, atexit.3, backtrace.3, bcmp.3, clearenv.3, ctime.3, dl_iterate_phdr.3, dlopen.3, ecvt.3, errno.3, error.3, ether_aton.3, exit.3, fenv.3, ferror.3, finite.3, flockfile.3, fnmatch.3, fpathconf.3, fpclassify.3, ftime.3, ftok.3, ftw.3, fwide.3, getaddrinfo.3, gethostbyname.3, getlogin.3, getnameinfo.3, getnetent.3, getopt.3, getprotoent.3, getrpcent.3, getservent.3, glob.3, hsearch.3, inet.3, isalpha.3, iswalnum.3, iswalpha.3, iswblank.3, iswcntrl.3, iswctype.3, iswdigit.3, iswgraph.3, iswlower.3, iswprint.3, iswpunct.3, iswspace.3, iswupper.3, iswxdigit.3, longjmp.3, lsearch.3, malloc.3, matherr.3, mblen.3, mbsinit.3, mbtowc.3, on_exit.3, printf.3, pthread_attr_init.3, pthread_attr_setaffinity_np.3, pthread_attr_setdetachstate.3, pthread_attr_setguardsize.3, pthread_attr_setinheritsched.3, pthread_attr_setschedparam.3, pthread_attr_setschedpolicy.3, pthread_attr_setscope.3, pthread_attr_setstack.3, pthread_attr_setstackaddr.3, pthread_attr_setstacksize.3, pthread_cancel.3, pthread_cleanup_push.3, pthread_equal.3, pthread_getattr_np.3, pthread_getcpuclockid.3, pthread_setaffinity_np.3, pthread_setcancelstate.3, pthread_setconcurrency.3, pthread_setschedparam.3, pthread_setschedprio.3, ptsname.3, putenv.3, putgrent.3, raise.3, rcmd.3, regex.3, rexec.3, rpc.3, rpmatch.3, rtnetlink.3, scandir.3, sem_init.3, setaliasent.3, setbuf.3, setenv.3, setjmp.3, signbit.3, stdio_ext.3, strtod.3, strtol.3, strtoul.3, system.3, termios.3, timeradd.3, tzset.3, ualarm.3, wctomb.3, xdr.3, st.4, tty_ioctl.4, core.5, elf.5, proc.5, bootparam.7, capabilities.7, icmp.7, ip.7, ipv6.7, math_error.7, mdoc.samples.7, mq_overview.7, pthreads.7, raw.7, regex.7, socket.7, tcp.7, tzselect.8: Global fix: s/non-zero/nonzero/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 16:40:55 +00:00
|
|
|
Valid error numbers are all nonzero; \fIerrno\fP is never set to zero
|
2008-07-08 12:32:50 +00:00
|
|
|
by any system call or library function.
|
|
|
|
|
|
|
|
For some system calls and library functions (e.g.,
|
|
|
|
.BR getpriority (2)),
|
|
|
|
\-1 is a valid return on success.
|
|
|
|
In such cases, a successful return can be distinguished from an error
|
|
|
|
return by setting
|
2007-06-22 06:05:43 +00:00
|
|
|
.I errno
|
2008-07-08 12:32:50 +00:00
|
|
|
to zero before the call, and then,
|
|
|
|
if the call returns a status that indicates that an error
|
|
|
|
may have occurred, checking to see if
|
|
|
|
.I errno
|
intro.1, time.1, adjtimex.2, capget.2, eventfd.2, fcntl.2, getrlimit.2, getsockopt.2, gettimeofday.2, intro.2, ioctl_list.2, ioperm.2, mlock.2, pivot_root.2, poll.2, prctl.2, ptrace.2, sched_setscheduler.2, select_tut.2, semget.2, sigaltstack.2, signalfd.2, sysctl.2, timer_settime.2, timerfd_create.2, wait.2, CPU_SET.3, argz_add.3, assert_perror.3, atexit.3, backtrace.3, bcmp.3, clearenv.3, ctime.3, dl_iterate_phdr.3, dlopen.3, ecvt.3, errno.3, error.3, ether_aton.3, exit.3, fenv.3, ferror.3, finite.3, flockfile.3, fnmatch.3, fpathconf.3, fpclassify.3, ftime.3, ftok.3, ftw.3, fwide.3, getaddrinfo.3, gethostbyname.3, getlogin.3, getnameinfo.3, getnetent.3, getopt.3, getprotoent.3, getrpcent.3, getservent.3, glob.3, hsearch.3, inet.3, isalpha.3, iswalnum.3, iswalpha.3, iswblank.3, iswcntrl.3, iswctype.3, iswdigit.3, iswgraph.3, iswlower.3, iswprint.3, iswpunct.3, iswspace.3, iswupper.3, iswxdigit.3, longjmp.3, lsearch.3, malloc.3, matherr.3, mblen.3, mbsinit.3, mbtowc.3, on_exit.3, printf.3, pthread_attr_init.3, pthread_attr_setaffinity_np.3, pthread_attr_setdetachstate.3, pthread_attr_setguardsize.3, pthread_attr_setinheritsched.3, pthread_attr_setschedparam.3, pthread_attr_setschedpolicy.3, pthread_attr_setscope.3, pthread_attr_setstack.3, pthread_attr_setstackaddr.3, pthread_attr_setstacksize.3, pthread_cancel.3, pthread_cleanup_push.3, pthread_equal.3, pthread_getattr_np.3, pthread_getcpuclockid.3, pthread_setaffinity_np.3, pthread_setcancelstate.3, pthread_setconcurrency.3, pthread_setschedparam.3, pthread_setschedprio.3, ptsname.3, putenv.3, putgrent.3, raise.3, rcmd.3, regex.3, rexec.3, rpc.3, rpmatch.3, rtnetlink.3, scandir.3, sem_init.3, setaliasent.3, setbuf.3, setenv.3, setjmp.3, signbit.3, stdio_ext.3, strtod.3, strtol.3, strtoul.3, system.3, termios.3, timeradd.3, tzset.3, ualarm.3, wctomb.3, xdr.3, st.4, tty_ioctl.4, core.5, elf.5, proc.5, bootparam.7, capabilities.7, icmp.7, ip.7, ipv6.7, math_error.7, mdoc.samples.7, mq_overview.7, pthreads.7, raw.7, regex.7, socket.7, tcp.7, tzselect.8: Global fix: s/non-zero/nonzero/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 16:40:55 +00:00
|
|
|
has a nonzero value.
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2007-07-18 20:24:30 +00:00
|
|
|
\fIerrno\fP is defined by the ISO C standard to be a modifiable lvalue
|
|
|
|
of type \fIint\fP, and must not be explicitly declared; \fIerrno\fP
|
2007-05-12 13:26:09 +00:00
|
|
|
may be a macro.
|
2007-07-18 20:24:30 +00:00
|
|
|
\fIerrno\fP is thread-local; setting it in one thread
|
2004-11-03 13:51:07 +00:00
|
|
|
does not affect its value in any other thread.
|
|
|
|
|
2007-04-12 22:42:49 +00:00
|
|
|
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
|
2007-07-18 20:24:30 +00:00
|
|
|
.\" these, \fBEDOM\fP and \fBERANGE\fP are in the ISO C standard. ISO C
|
|
|
|
.\" Amendment 1 defines the additional error number \fBEILSEQ\fP for
|
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
|
|
|
.\" 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.
|
2008-01-27 12:08:05 +00:00
|
|
|
.TP 16
|
2007-09-20 16:26:31 +00:00
|
|
|
.B E2BIG
|
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
|
|
|
Argument list too long (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EACCES
|
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
|
|
|
Permission denied (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EADDRINUSE
|
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
|
|
|
Address already in use (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EADDRNOTAVAIL
|
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
|
|
|
Address not available (POSIX.1)
|
|
|
|
.\" EADV is only an error on HURD(?)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EAFNOSUPPORT
|
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
|
|
|
Address family not supported (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B 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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EALREADY
|
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
|
|
|
Connection already in progress (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADE
|
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
|
|
|
Invalid exchange
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADF
|
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
|
|
|
Bad file descriptor (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADFD
|
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
|
|
|
File descriptor in bad state
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADMSG
|
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
|
|
|
Bad message (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADR
|
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
|
|
|
Invalid request descriptor
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADRQC
|
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
|
|
|
Invalid request code
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBADSLT
|
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
|
|
|
Invalid slot
|
|
|
|
.\" EBFONT is defined but appears not to be used by kernel or glibc.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EBUSY
|
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
|
|
|
Device or resource busy (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ECANCELED
|
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
|
|
|
Operation canceled (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ECHILD
|
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
|
|
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ECONNABORTED
|
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
|
|
|
Connection aborted (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ECONNREFUSED
|
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
|
|
|
Connection refused (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ECONNRESET
|
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
|
|
|
Connection reset (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EDEADLK
|
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
|
|
|
Resource deadlock avoided (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EDEADLOCK
|
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
|
|
|
Synonym for
|
2004-11-03 13:51:07 +00:00
|
|
|
.B EDEADLK
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EDESTADDRREQ
|
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
|
|
|
Destination address required (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EDOM
|
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
|
|
|
Mathematics argument out of domain of function (POSIX.1, C99)
|
|
|
|
.\" EDOTDOT is defined but appears to be unused
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EDQUOT
|
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 just says "Reserved"
|
|
|
|
Disk quota exceeded (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EEXIST
|
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
|
|
|
File exists (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EFAULT
|
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
|
|
|
Bad address (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EFBIG
|
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
|
|
|
File too large (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EHOSTDOWN
|
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
|
|
|
Host is down
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EHOSTUNREACH
|
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
|
|
|
Host is unreachable (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EIDRM
|
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
|
|
|
Identifier removed (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EILSEQ
|
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
|
|
|
Illegal byte sequence (POSIX.1, C99)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EINPROGRESS
|
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
|
|
|
Operation in progress (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EINTR
|
2008-07-04 11:32:03 +00:00
|
|
|
Interrupted function call (POSIX.1); see
|
|
|
|
.BR signal (7).
|
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
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EINVAL
|
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
|
|
|
Invalid argument (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EIO
|
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
|
|
|
Input/output error (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EISCONN
|
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
|
|
|
Socket is connected (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EISDIR
|
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
|
|
|
Is a directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EISNAM
|
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
|
|
|
Is a named type file
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EKEYEXPIRED
|
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
|
|
|
Key has expired
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EKEYREJECTED
|
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
|
|
|
Key was rejected by service
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EKEYREVOKED
|
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
|
|
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELIBACC
|
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
|
|
|
Cannot access a needed shared library
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELIBBAD
|
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
|
|
|
Accessing a corrupted shared library
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELIBMAX
|
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
|
|
|
Attempting to link in too many shared libraries
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELIBSCN
|
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
|
|
|
lib section in a.out corrupted
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELIBEXEC
|
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
|
|
|
Cannot exec a shared library directly
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ELOOP
|
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
|
|
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EMEDIUMTYPE
|
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
|
|
|
Wrong medium type
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EMFILE
|
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
|
|
|
Too many open files (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EMLINK
|
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
|
|
|
Too many links (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EMSGSIZE
|
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
|
|
|
Message too long (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EMULTIHOP
|
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 says "Reserved"
|
|
|
|
Multihop attempted (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENAMETOOLONG
|
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
|
|
|
Filename too long (POSIX.1)
|
|
|
|
.\" ENAVAIL is defined, but appears not to be used
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENETDOWN
|
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
|
|
|
Network is down (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENETRESET
|
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
|
|
|
Connection aborted by network (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENETUNREACH
|
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
|
|
|
Network unreachable (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENFILE
|
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
|
|
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOBUFS
|
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
|
|
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENODATA
|
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
|
|
|
No message is available on the STREAM head read queue (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENODEV
|
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
|
|
|
No such device (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOENT
|
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
|
|
|
No such file or directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOEXEC
|
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
|
|
|
Exec format error (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOKEY
|
2006-05-29 01:20:08 +00:00
|
|
|
Required key not available
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOLCK
|
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
|
|
|
No locks available (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOLINK
|
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 says "Reserved"
|
|
|
|
Link has been severed (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOMEDIUM
|
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
|
|
|
No medium found
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOMEM
|
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 enough space (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOMSG
|
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
|
|
|
No message of the desired type (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENONET
|
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
|
|
|
Machine is not on the network
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOPKG
|
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
|
|
|
Package not installed
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOPROTOOPT
|
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
|
|
|
Protocol not available (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOSPC
|
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
|
|
|
No space left on device (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOSR
|
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
|
|
|
No STREAM resources (POSIX.1 (XSI STREAMS option))
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B 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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOSYS
|
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
|
|
|
Function not implemented (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTBLK
|
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
|
|
|
Block device required
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTCONN
|
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
|
|
|
The socket is not connected (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTDIR
|
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 directory (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTEMPTY
|
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
|
|
|
Directory not empty (POSIX.1)
|
|
|
|
.\" ENOTNAM is defined but appears to be unused.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTSOCK
|
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 socket (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTSUP
|
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
|
|
|
Operation not supported (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTTY
|
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
|
|
|
Inappropriate I/O control operation (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENOTUNIQ
|
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
|
|
|
Name not unique on network
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ENXIO
|
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
|
|
|
No such device or address (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EOPNOTSUPP
|
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
|
|
|
Operation not supported on socket (POSIX.1)
|
|
|
|
.sp
|
2007-06-22 19:42:52 +00:00
|
|
|
.RB ( ENOTSUP
|
|
|
|
and
|
|
|
|
.B EOPNOTSUPP
|
|
|
|
have the same value on Linux, but
|
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
|
|
|
according to POSIX.1 these error values should be distinct.)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EOVERFLOW
|
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
|
|
|
Value too large to be stored in data type (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPERM
|
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
|
|
|
Operation not permitted (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPFNOSUPPORT
|
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
|
|
|
Protocol family not supported
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPIPE
|
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
|
|
|
Broken pipe (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPROTO
|
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
|
|
|
Protocol error (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPROTONOSUPPORT
|
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
|
|
|
Protocol not supported (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EPROTOTYPE
|
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
|
|
|
Protocol wrong type for socket (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ERANGE
|
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
|
|
|
Result too large (POSIX.1, C99)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EREMCHG
|
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
|
|
|
Remote address changed
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EREMOTE
|
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
|
|
|
Object is remote
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EREMOTEIO
|
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
|
|
|
Remote I/O error
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ERESTART
|
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
|
|
|
Interrupted system call should be restarted
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EROFS
|
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
|
|
|
Read-only file system (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ESHUTDOWN
|
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
|
|
|
Cannot send after transport endpoint shutdown
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ESPIPE
|
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
|
|
|
Invalid seek (POSIX.1)
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ESOCKTNOSUPPORT
|
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
|
|
|
Socket type not supported
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ESRCH
|
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
|
|
|
No such process (POSIX.1)
|
|
|
|
.\" ESRMNT is defined but appears not to be used
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B 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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ESTRPIPE
|
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
|
|
|
Streams pipe error
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ETIME
|
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
|
|
|
Timer expired
|
|
|
|
(POSIX.1 (XSI STREAMS option))
|
|
|
|
.sp
|
2007-04-12 22:42:49 +00:00
|
|
|
(POSIX.1 says "STREAM
|
2007-05-21 21:23:17 +00:00
|
|
|
.BR ioctl (2)
|
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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ETIMEDOUT
|
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
|
|
|
Connection timed out (POSIX.1)
|
|
|
|
.\" ETOOMANYREFS is defined, but appears not to be used.
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B ETXTBSY
|
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
|
|
|
Text file busy (POSIX.1)
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EUCLEAN
|
2006-03-20 03:13:48 +00:00
|
|
|
Structure needs cleaning
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EUNATCH
|
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
|
|
|
Protocol driver not attached
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EUSERS
|
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
|
|
|
Too many users
|
|
|
|
.TP
|
2007-09-20 16:26:31 +00:00
|
|
|
.B 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
|
2007-09-20 16:26:31 +00:00
|
|
|
.B EXDEV
|
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
|
|
|
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
|
2007-12-19 07:19:23 +00:00
|
|
|
.in +4n
|
2004-11-03 13:51:07 +00:00
|
|
|
.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
|
2007-12-19 07:19:23 +00:00
|
|
|
.in
|
2004-11-03 13:51:07 +00:00
|
|
|
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
|
2007-05-12 00:30:29 +00:00
|
|
|
.BR printf (3)).
|
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:
|
2007-12-19 07:19:23 +00:00
|
|
|
.in +4n
|
2004-11-03 13:51:07 +00:00
|
|
|
.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
|
2007-12-19 07:19:23 +00:00
|
|
|
.in
|
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.
|
intro.1, time.1, accept.2, bind.2, connect.2, execve.2, flock.2, getdents.2, getpriority.2, getuid.2, intro.2, ioctl.2, mincore.2, mknod.2, personality.2, ptrace.2, read.2, recv.2, select_tut.2, send.2, sendfile.2, shmctl.2, sigaction.2, signal.2, stat.2, times.2, truncate.2, umask.2, wait.2, MB_CUR_MAX.3, MB_LEN_MAX.3, argz_add.3, btowc.3, clearenv.3, clock.3, cmsg.3, end.3, endian.3, errno.3, exit.3, fgetwc.3, fgetws.3, fopen.3, fputwc.3, fputws.3, fseek.3, fwide.3, getfsent.3, getgrnam.3, gethostid.3, getipnodebyname.3, getmntent.3, getpwnam.3, getwchar.3, grantpt.3, iconv.3, iconv_close.3, iconv_open.3, insque.3, intro.3, iswalnum.3, iswalpha.3, iswblank.3, iswcntrl.3, iswctype.3, iswdigit.3, iswgraph.3, iswlower.3, iswprint.3, iswpunct.3, iswspace.3, iswupper.3, iswxdigit.3, malloc.3, mblen.3, mbrlen.3, mbrtowc.3, mbsinit.3, mbsnrtowcs.3, mbsrtowcs.3, mbstowcs.3, mbtowc.3, mkstemp.3, mktemp.3, nl_langinfo.3, openpty.3, posix_openpt.3, printf.3, ptsname.3, putwchar.3, qecvt.3, rcmd.3, readdir.3, rexec.3, rpc.3, setnetgrent.3, shm_open.3, sigpause.3, stdin.3, stpcpy.3, strftime.3, strptime.3, syslog.3, towctrans.3, towlower.3, towupper.3, ttyslot.3, ungetwc.3, unlocked_stdio.3, wcpcpy.3, wcpncpy.3, wcrtomb.3, wcscasecmp.3, wcscat.3, wcschr.3, wcscmp.3, wcscpy.3, wcscspn.3, wcsdup.3, wcslen.3, wcsncasecmp.3, wcsncat.3, wcsncmp.3, wcsncpy.3, wcsnlen.3, wcsnrtombs.3, wcspbrk.3, wcsrchr.3, wcsrtombs.3, wcsspn.3, wcsstr.3, wcstok.3, wcstombs.3, wcswidth.3, wctob.3, wctomb.3, wctrans.3, wctype.3, wcwidth.3, wmemchr.3, wmemcmp.3, wmemcpy.3, wmemmove.3, wmemset.3, wprintf.3, console_ioctl.4, pts.4, elf.5, filesystems.5, hosts.5, proc.5, ttytype.5, boot.7, capabilities.7, credentials.7, epoll.7, glob.7, koi8-r.7, path_resolution.7, pty.7, signal.7, suffixes.7, time.7, unicode.7, unix.7, uri.7, utf-8.7: global fix: s/Unix/UNIX/
The man pages were rather inconsistent in the use of "Unix"
versus "UNIX". Let's go with the trademark usage.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-10-12 04:45:38 +00:00
|
|
|
However, on (very) old UNIX systems, there may be no
|
2004-12-17 12:20:07 +00:00
|
|
|
.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)
|