errlist.c 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. /* $OpenBSD: errlist.c,v 1.14 2009/11/24 09:22:22 guenther Exp $ */
  2. /*
  3. * Copyright (c) 1982, 1985, 1993
  4. * The Regents of the University of California. All rights reserved.
  5. *
  6. * Redistribution and use in source and binary forms, with or without
  7. * modification, are permitted provided that the following conditions
  8. * are met:
  9. * 1. Redistributions of source code must retain the above copyright
  10. * notice, this list of conditions and the following disclaimer.
  11. * 2. Redistributions in binary form must reproduce the above copyright
  12. * notice, this list of conditions and the following disclaimer in the
  13. * documentation and/or other materials provided with the distribution.
  14. * 3. Neither the name of the University nor the names of its contributors
  15. * may be used to endorse or promote products derived from this software
  16. * without specific prior written permission.
  17. *
  18. * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  19. * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  20. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  21. * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  22. * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  23. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  24. * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  25. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  26. * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  27. * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  28. * SUCH DAMAGE.
  29. */
  30. #define _sys_errlist sys_errlist
  31. #define _sys_nerr sys_nerr
  32. const char *const
  33. _sys_errlist[] = {
  34. "Undefined error: 0", /* 0 - ENOERROR */
  35. "Operation not permitted", /* 1 - EPERM */
  36. "No such file or directory", /* 2 - ENOENT */
  37. "No such process", /* 3 - ESRCH */
  38. "Interrupted system call", /* 4 - EINTR */
  39. "Input/output error", /* 5 - EIO */
  40. "Device not configured", /* 6 - ENXIO */
  41. "Argument list too long", /* 7 - E2BIG */
  42. "Exec format error", /* 8 - ENOEXEC */
  43. "Bad file descriptor", /* 9 - EBADF */
  44. "No child processes", /* 10 - ECHILD */
  45. "Resource deadlock avoided", /* 11 - EDEADLK */
  46. "Cannot allocate memory", /* 12 - ENOMEM */
  47. "Permission denied", /* 13 - EACCES */
  48. "Bad address", /* 14 - EFAULT */
  49. "Block device required", /* 15 - ENOTBLK */
  50. "Device busy", /* 16 - EBUSY */
  51. "File exists", /* 17 - EEXIST */
  52. "Cross-device link", /* 18 - EXDEV */
  53. "Operation not supported by device", /* 19 - ENODEV */
  54. "Not a directory", /* 20 - ENOTDIR */
  55. "Is a directory", /* 21 - EISDIR */
  56. "Invalid argument", /* 22 - EINVAL */
  57. "Too many open files in system", /* 23 - ENFILE */
  58. "Too many open files", /* 24 - EMFILE */
  59. "Inappropriate ioctl for device", /* 25 - ENOTTY */
  60. "Text file busy", /* 26 - ETXTBSY */
  61. "File too large", /* 27 - EFBIG */
  62. "No space left on device", /* 28 - ENOSPC */
  63. "Illegal seek", /* 29 - ESPIPE */
  64. "Read-only file system", /* 30 - EROFS */
  65. "Too many links", /* 31 - EMLINK */
  66. "Broken pipe", /* 32 - EPIPE */
  67. /* math software */
  68. "Numerical argument out of domain", /* 33 - EDOM */
  69. "Result too large", /* 34 - ERANGE */
  70. /* non-blocking and interrupt i/o */
  71. "Resource temporarily unavailable", /* 35 - EAGAIN */
  72. /* 35 - EWOULDBLOCK */
  73. "Operation now in progress", /* 36 - EINPROGRESS */
  74. "Operation already in progress", /* 37 - EALREADY */
  75. /* ipc/network software -- argument errors */
  76. "Socket operation on non-socket", /* 38 - ENOTSOCK */
  77. "Destination address required", /* 39 - EDESTADDRREQ */
  78. "Message too long", /* 40 - EMSGSIZE */
  79. "Protocol wrong type for socket", /* 41 - EPROTOTYPE */
  80. "Protocol not available", /* 42 - ENOPROTOOPT */
  81. "Protocol not supported", /* 43 - EPROTONOSUPPORT */
  82. "Socket type not supported", /* 44 - ESOCKTNOSUPPORT */
  83. "Operation not supported", /* 45 - EOPNOTSUPP */
  84. "Protocol family not supported", /* 46 - EPFNOSUPPORT */
  85. /* 47 - EAFNOSUPPORT */
  86. "Address family not supported by protocol family",
  87. "Address already in use", /* 48 - EADDRINUSE */
  88. "Can't assign requested address", /* 49 - EADDRNOTAVAIL */
  89. /* ipc/network software -- operational errors */
  90. "Network is down", /* 50 - ENETDOWN */
  91. "Network is unreachable", /* 51 - ENETUNREACH */
  92. "Network dropped connection on reset", /* 52 - ENETRESET */
  93. "Software caused connection abort", /* 53 - ECONNABORTED */
  94. "Connection reset by peer", /* 54 - ECONNRESET */
  95. "No buffer space available", /* 55 - ENOBUFS */
  96. "Socket is already connected", /* 56 - EISCONN */
  97. "Socket is not connected", /* 57 - ENOTCONN */
  98. "Can't send after socket shutdown", /* 58 - ESHUTDOWN */
  99. "Too many references: can't splice", /* 59 - ETOOMANYREFS */
  100. "Operation timed out", /* 60 - ETIMEDOUT */
  101. "Connection refused", /* 61 - ECONNREFUSED */
  102. "Too many levels of symbolic links", /* 62 - ELOOP */
  103. "File name too long", /* 63 - ENAMETOOLONG */
  104. /* should be rearranged */
  105. "Host is down", /* 64 - EHOSTDOWN */
  106. "No route to host", /* 65 - EHOSTUNREACH */
  107. "Directory not empty", /* 66 - ENOTEMPTY */
  108. /* quotas & mush */
  109. "Too many processes", /* 67 - EPROCLIM */
  110. "Too many users", /* 68 - EUSERS */
  111. "Disk quota exceeded", /* 69 - EDQUOT */
  112. /* Network File System */
  113. "Stale NFS file handle", /* 70 - ESTALE */
  114. "Too many levels of remote in path", /* 71 - EREMOTE */
  115. "RPC struct is bad", /* 72 - EBADRPC */
  116. "RPC version wrong", /* 73 - ERPCMISMATCH */
  117. "RPC prog. not avail", /* 74 - EPROGUNAVAIL */
  118. "Program version wrong", /* 75 - EPROGMISMATCH */
  119. "Bad procedure for program", /* 76 - EPROCUNAVAIL */
  120. "No locks available", /* 77 - ENOLCK */
  121. "Function not implemented", /* 78 - ENOSYS */
  122. "Inappropriate file type or format", /* 79 - EFTYPE */
  123. "Authentication error", /* 80 - EAUTH */
  124. "Need authenticator", /* 81 - ENEEDAUTH */
  125. "IPsec processing failure", /* 82 - EIPSEC */
  126. "Attribute not found", /* 83 - ENOATTR */
  127. "Illegal byte sequence", /* 84 - EILSEQ */
  128. "No medium found", /* 85 - ENOMEDIUM */
  129. "Wrong medium type", /* 86 - EMEDIUMTYPE */
  130. /* 87 - EOVERFLOW */
  131. "Value too large to be stored in data type",
  132. "Operation canceled", /* 88 - ECANCELED */
  133. "Identifier removed", /* 89 - EIDRM */
  134. "No message of desired type", /* 90 - ENOMSG */
  135. "Not supported", /* 91 - ENOTSUP */
  136. };
  137. int _sys_nerr = { sizeof _sys_errlist/sizeof _sys_errlist[0] };