]> git.proxmox.com Git - mirror_edk2.git/blobdiff - AppPkg/Applications/Python/Python-2.7.10/PyMod-2.7.10/Modules/errnomodule.c
edk2: Remove AppPkg, StdLib, StdLibPrivateInternalFiles
[mirror_edk2.git] / AppPkg / Applications / Python / Python-2.7.10 / PyMod-2.7.10 / Modules / errnomodule.c
diff --git a/AppPkg/Applications/Python/Python-2.7.10/PyMod-2.7.10/Modules/errnomodule.c b/AppPkg/Applications/Python/Python-2.7.10/PyMod-2.7.10/Modules/errnomodule.c
deleted file mode 100644 (file)
index 615af2c..0000000
+++ /dev/null
@@ -1,844 +0,0 @@
-/* Errno module\r
-\r
-    Copyright (c) 2011 - 2012, Intel Corporation. All rights reserved.<BR>\r
-    This program and the accompanying materials are licensed and made available under\r
-    the terms and conditions of the BSD License that accompanies this distribution.\r
-    The full text of the license may be found at\r
-    http://opensource.org/licenses/bsd-license.\r
-\r
-    THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-    WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-*/\r
-\r
-#include "Python.h"\r
-\r
-/* Windows socket errors (WSA*)  */\r
-#ifdef MS_WINDOWS\r
-#include <windows.h>\r
-#endif\r
-\r
-/*\r
- * Pull in the system error definitions\r
- */\r
-\r
-static PyMethodDef errno_methods[] = {\r
-    {NULL,              NULL}\r
-};\r
-\r
-/* Helper function doing the dictionary inserting */\r
-\r
-static void\r
-_inscode(PyObject *d, PyObject *de, char *name, int code)\r
-{\r
-    PyObject *u = PyString_FromString(name);\r
-    PyObject *v = PyInt_FromLong((long) code);\r
-\r
-    /* Don't bother checking for errors; they'll be caught at the end\r
-     * of the module initialization function by the caller of\r
-     * initerrno().\r
-     */\r
-    if (u && v) {\r
-        /* insert in modules dict */\r
-        PyDict_SetItem(d, u, v);\r
-        /* insert in errorcode dict */\r
-        PyDict_SetItem(de, v, u);\r
-    }\r
-    Py_XDECREF(u);\r
-    Py_XDECREF(v);\r
-}\r
-\r
-PyDoc_STRVAR(errno__doc__,\r
-"This module makes available standard errno system symbols.\n\\r
-\n\\r
-The value of each symbol is the corresponding integer value,\n\\r
-e.g., on most systems, errno.ENOENT equals the integer 2.\n\\r
-\n\\r
-The dictionary errno.errorcode maps numeric codes to symbol names,\n\\r
-e.g., errno.errorcode[2] could be the string 'ENOENT'.\n\\r
-\n\\r
-Symbols that are not relevant to the underlying system are not defined.\n\\r
-\n\\r
-To map error codes to error messages, use the function os.strerror(),\n\\r
-e.g. os.strerror(2) could return 'No such file or directory'.");\r
-\r
-PyMODINIT_FUNC\r
-initerrno(void)\r
-{\r
-    PyObject *m, *d, *de;\r
-    m = Py_InitModule3("errno", errno_methods, errno__doc__);\r
-    if (m == NULL)\r
-        return;\r
-    d = PyModule_GetDict(m);\r
-    de = PyDict_New();\r
-    if (!d || !de || PyDict_SetItemString(d, "errorcode", de) < 0)\r
-        return;\r
-\r
-/* Macro so I don't have to edit each and every line below... */\r
-#define inscode(d, ds, de, name, code, comment) _inscode(d, de, name, code)\r
-\r
-    /*\r
-     * The names and comments are borrowed from linux/include/errno.h,\r
-     * which should be pretty all-inclusive\r
-     */\r
-\r
-#ifdef ENODEV\r
-    inscode(d, ds, de, "ENODEV", ENODEV, "No such device");\r
-#endif\r
-#ifdef ENOCSI\r
-    inscode(d, ds, de, "ENOCSI", ENOCSI, "No CSI structure available");\r
-#endif\r
-#ifdef EHOSTUNREACH\r
-    inscode(d, ds, de, "EHOSTUNREACH", EHOSTUNREACH, "No route to host");\r
-#else\r
-#ifdef WSAEHOSTUNREACH\r
-    inscode(d, ds, de, "EHOSTUNREACH", WSAEHOSTUNREACH, "No route to host");\r
-#endif\r
-#endif\r
-#ifdef ENOMSG\r
-    inscode(d, ds, de, "ENOMSG", ENOMSG, "No message of desired type");\r
-#endif\r
-#ifdef EUCLEAN\r
-    inscode(d, ds, de, "EUCLEAN", EUCLEAN, "Structure needs cleaning");\r
-#endif\r
-#ifdef EL2NSYNC\r
-    inscode(d, ds, de, "EL2NSYNC", EL2NSYNC, "Level 2 not synchronized");\r
-#endif\r
-#ifdef EL2HLT\r
-    inscode(d, ds, de, "EL2HLT", EL2HLT, "Level 2 halted");\r
-#endif\r
-#ifdef ENODATA\r
-    inscode(d, ds, de, "ENODATA", ENODATA, "No data available");\r
-#endif\r
-#ifdef ENOTBLK\r
-    inscode(d, ds, de, "ENOTBLK", ENOTBLK, "Block device required");\r
-#endif\r
-#ifdef ENOSYS\r
-    inscode(d, ds, de, "ENOSYS", ENOSYS, "Function not implemented");\r
-#endif\r
-#ifdef EPIPE\r
-    inscode(d, ds, de, "EPIPE", EPIPE, "Broken pipe");\r
-#endif\r
-#ifdef EINVAL\r
-    inscode(d, ds, de, "EINVAL", EINVAL, "Invalid argument");\r
-#else\r
-#ifdef WSAEINVAL\r
-    inscode(d, ds, de, "EINVAL", WSAEINVAL, "Invalid argument");\r
-#endif\r
-#endif\r
-#ifdef EOVERFLOW\r
-    inscode(d, ds, de, "EOVERFLOW", EOVERFLOW, "Value too large for defined data type");\r
-#endif\r
-#ifdef EADV\r
-    inscode(d, ds, de, "EADV", EADV, "Advertise error");\r
-#endif\r
-#ifdef EINTR\r
-    inscode(d, ds, de, "EINTR", EINTR, "Interrupted system call");\r
-#else\r
-#ifdef WSAEINTR\r
-    inscode(d, ds, de, "EINTR", WSAEINTR, "Interrupted system call");\r
-#endif\r
-#endif\r
-#ifdef EUSERS\r
-    inscode(d, ds, de, "EUSERS", EUSERS, "Too many users");\r
-#else\r
-#ifdef WSAEUSERS\r
-    inscode(d, ds, de, "EUSERS", WSAEUSERS, "Too many users");\r
-#endif\r
-#endif\r
-#ifdef ENOTEMPTY\r
-    inscode(d, ds, de, "ENOTEMPTY", ENOTEMPTY, "Directory not empty");\r
-#else\r
-#ifdef WSAENOTEMPTY\r
-    inscode(d, ds, de, "ENOTEMPTY", WSAENOTEMPTY, "Directory not empty");\r
-#endif\r
-#endif\r
-#ifdef ENOBUFS\r
-    inscode(d, ds, de, "ENOBUFS", ENOBUFS, "No buffer space available");\r
-#else\r
-#ifdef WSAENOBUFS\r
-    inscode(d, ds, de, "ENOBUFS", WSAENOBUFS, "No buffer space available");\r
-#endif\r
-#endif\r
-#ifdef EPROTO\r
-    inscode(d, ds, de, "EPROTO", EPROTO, "Protocol error");\r
-#endif\r
-#ifdef EREMOTE\r
-    inscode(d, ds, de, "EREMOTE", EREMOTE, "Object is remote");\r
-#else\r
-#ifdef WSAEREMOTE\r
-    inscode(d, ds, de, "EREMOTE", WSAEREMOTE, "Object is remote");\r
-#endif\r
-#endif\r
-#ifdef ENAVAIL\r
-    inscode(d, ds, de, "ENAVAIL", ENAVAIL, "No XENIX semaphores available");\r
-#endif\r
-#ifdef ECHILD\r
-    inscode(d, ds, de, "ECHILD", ECHILD, "No child processes");\r
-#endif\r
-#ifdef ELOOP\r
-    inscode(d, ds, de, "ELOOP", ELOOP, "Too many symbolic links encountered");\r
-#else\r
-#ifdef WSAELOOP\r
-    inscode(d, ds, de, "ELOOP", WSAELOOP, "Too many symbolic links encountered");\r
-#endif\r
-#endif\r
-#ifdef EXDEV\r
-    inscode(d, ds, de, "EXDEV", EXDEV, "Cross-device link");\r
-#endif\r
-#ifdef E2BIG\r
-    inscode(d, ds, de, "E2BIG", E2BIG, "Arg list too long");\r
-#endif\r
-#ifdef ESRCH\r
-    inscode(d, ds, de, "ESRCH", ESRCH, "No such process");\r
-#endif\r
-#ifdef EMSGSIZE\r
-    inscode(d, ds, de, "EMSGSIZE", EMSGSIZE, "Message too long");\r
-#else\r
-#ifdef WSAEMSGSIZE\r
-    inscode(d, ds, de, "EMSGSIZE", WSAEMSGSIZE, "Message too long");\r
-#endif\r
-#endif\r
-#ifdef EAFNOSUPPORT\r
-    inscode(d, ds, de, "EAFNOSUPPORT", EAFNOSUPPORT, "Address family not supported by protocol");\r
-#else\r
-#ifdef WSAEAFNOSUPPORT\r
-    inscode(d, ds, de, "EAFNOSUPPORT", WSAEAFNOSUPPORT, "Address family not supported by protocol");\r
-#endif\r
-#endif\r
-#ifdef EBADR\r
-    inscode(d, ds, de, "EBADR", EBADR, "Invalid request descriptor");\r
-#endif\r
-#ifdef EHOSTDOWN\r
-    inscode(d, ds, de, "EHOSTDOWN", EHOSTDOWN, "Host is down");\r
-#else\r
-#ifdef WSAEHOSTDOWN\r
-    inscode(d, ds, de, "EHOSTDOWN", WSAEHOSTDOWN, "Host is down");\r
-#endif\r
-#endif\r
-#ifdef EPFNOSUPPORT\r
-    inscode(d, ds, de, "EPFNOSUPPORT", EPFNOSUPPORT, "Protocol family not supported");\r
-#else\r
-#ifdef WSAEPFNOSUPPORT\r
-    inscode(d, ds, de, "EPFNOSUPPORT", WSAEPFNOSUPPORT, "Protocol family not supported");\r
-#endif\r
-#endif\r
-#ifdef ENOPROTOOPT\r
-    inscode(d, ds, de, "ENOPROTOOPT", ENOPROTOOPT, "Protocol not available");\r
-#else\r
-#ifdef WSAENOPROTOOPT\r
-    inscode(d, ds, de, "ENOPROTOOPT", WSAENOPROTOOPT, "Protocol not available");\r
-#endif\r
-#endif\r
-#ifdef EBUSY\r
-    inscode(d, ds, de, "EBUSY", EBUSY, "Device or resource busy");\r
-#endif\r
-#ifdef EWOULDBLOCK\r
-    inscode(d, ds, de, "EWOULDBLOCK", EWOULDBLOCK, "Operation would block");\r
-#else\r
-#ifdef WSAEWOULDBLOCK\r
-    inscode(d, ds, de, "EWOULDBLOCK", WSAEWOULDBLOCK, "Operation would block");\r
-#endif\r
-#endif\r
-#ifdef EBADFD\r
-    inscode(d, ds, de, "EBADFD", EBADFD, "File descriptor in bad state");\r
-#endif\r
-#ifdef EDOTDOT\r
-    inscode(d, ds, de, "EDOTDOT", EDOTDOT, "RFS specific error");\r
-#endif\r
-#ifdef EISCONN\r
-    inscode(d, ds, de, "EISCONN", EISCONN, "Transport endpoint is already connected");\r
-#else\r
-#ifdef WSAEISCONN\r
-    inscode(d, ds, de, "EISCONN", WSAEISCONN, "Transport endpoint is already connected");\r
-#endif\r
-#endif\r
-#ifdef ENOANO\r
-    inscode(d, ds, de, "ENOANO", ENOANO, "No anode");\r
-#endif\r
-#ifdef ESHUTDOWN\r
-    inscode(d, ds, de, "ESHUTDOWN", ESHUTDOWN, "Cannot send after transport endpoint shutdown");\r
-#else\r
-#ifdef WSAESHUTDOWN\r
-    inscode(d, ds, de, "ESHUTDOWN", WSAESHUTDOWN, "Cannot send after transport endpoint shutdown");\r
-#endif\r
-#endif\r
-#ifdef ECHRNG\r
-    inscode(d, ds, de, "ECHRNG", ECHRNG, "Channel number out of range");\r
-#endif\r
-#ifdef ELIBBAD\r
-    inscode(d, ds, de, "ELIBBAD", ELIBBAD, "Accessing a corrupted shared library");\r
-#endif\r
-#ifdef ENONET\r
-    inscode(d, ds, de, "ENONET", ENONET, "Machine is not on the network");\r
-#endif\r
-#ifdef EBADE\r
-    inscode(d, ds, de, "EBADE", EBADE, "Invalid exchange");\r
-#endif\r
-#ifdef EBADF\r
-    inscode(d, ds, de, "EBADF", EBADF, "Bad file number");\r
-#else\r
-#ifdef WSAEBADF\r
-    inscode(d, ds, de, "EBADF", WSAEBADF, "Bad file number");\r
-#endif\r
-#endif\r
-#ifdef EMULTIHOP\r
-    inscode(d, ds, de, "EMULTIHOP", EMULTIHOP, "Multihop attempted");\r
-#endif\r
-#ifdef EIO\r
-    inscode(d, ds, de, "EIO", EIO, "I/O error");\r
-#endif\r
-#ifdef EUNATCH\r
-    inscode(d, ds, de, "EUNATCH", EUNATCH, "Protocol driver not attached");\r
-#endif\r
-#ifdef EPROTOTYPE\r
-    inscode(d, ds, de, "EPROTOTYPE", EPROTOTYPE, "Protocol wrong type for socket");\r
-#else\r
-#ifdef WSAEPROTOTYPE\r
-    inscode(d, ds, de, "EPROTOTYPE", WSAEPROTOTYPE, "Protocol wrong type for socket");\r
-#endif\r
-#endif\r
-#ifdef ENOSPC\r
-    inscode(d, ds, de, "ENOSPC", ENOSPC, "No space left on device");\r
-#endif\r
-#ifdef ENOEXEC\r
-    inscode(d, ds, de, "ENOEXEC", ENOEXEC, "Exec format error");\r
-#endif\r
-#ifdef EALREADY\r
-    inscode(d, ds, de, "EALREADY", EALREADY, "Operation already in progress");\r
-#else\r
-#ifdef WSAEALREADY\r
-    inscode(d, ds, de, "EALREADY", WSAEALREADY, "Operation already in progress");\r
-#endif\r
-#endif\r
-#ifdef ENETDOWN\r
-    inscode(d, ds, de, "ENETDOWN", ENETDOWN, "Network is down");\r
-#else\r
-#ifdef WSAENETDOWN\r
-    inscode(d, ds, de, "ENETDOWN", WSAENETDOWN, "Network is down");\r
-#endif\r
-#endif\r
-#ifdef ENOTNAM\r
-    inscode(d, ds, de, "ENOTNAM", ENOTNAM, "Not a XENIX named type file");\r
-#endif\r
-#ifdef EACCES\r
-    inscode(d, ds, de, "EACCES", EACCES, "Permission denied");\r
-#else\r
-#ifdef WSAEACCES\r
-    inscode(d, ds, de, "EACCES", WSAEACCES, "Permission denied");\r
-#endif\r
-#endif\r
-#ifdef ELNRNG\r
-    inscode(d, ds, de, "ELNRNG", ELNRNG, "Link number out of range");\r
-#endif\r
-#ifdef EILSEQ\r
-    inscode(d, ds, de, "EILSEQ", EILSEQ, "Illegal byte sequence");\r
-#endif\r
-#ifdef ENOTDIR\r
-    inscode(d, ds, de, "ENOTDIR", ENOTDIR, "Not a directory");\r
-#endif\r
-#ifdef ENOTUNIQ\r
-    inscode(d, ds, de, "ENOTUNIQ", ENOTUNIQ, "Name not unique on network");\r
-#endif\r
-#ifdef EPERM\r
-    inscode(d, ds, de, "EPERM", EPERM, "Operation not permitted");\r
-#endif\r
-#ifdef EDOM\r
-    inscode(d, ds, de, "EDOM", EDOM, "Math argument out of domain of func");\r
-#endif\r
-#ifdef EXFULL\r
-    inscode(d, ds, de, "EXFULL", EXFULL, "Exchange full");\r
-#endif\r
-#ifdef ECONNREFUSED\r
-    inscode(d, ds, de, "ECONNREFUSED", ECONNREFUSED, "Connection refused");\r
-#else\r
-#ifdef WSAECONNREFUSED\r
-    inscode(d, ds, de, "ECONNREFUSED", WSAECONNREFUSED, "Connection refused");\r
-#endif\r
-#endif\r
-#ifdef EISDIR\r
-    inscode(d, ds, de, "EISDIR", EISDIR, "Is a directory");\r
-#endif\r
-#ifdef EPROTONOSUPPORT\r
-    inscode(d, ds, de, "EPROTONOSUPPORT", EPROTONOSUPPORT, "Protocol not supported");\r
-#else\r
-#ifdef WSAEPROTONOSUPPORT\r
-    inscode(d, ds, de, "EPROTONOSUPPORT", WSAEPROTONOSUPPORT, "Protocol not supported");\r
-#endif\r
-#endif\r
-#ifdef EROFS\r
-    inscode(d, ds, de, "EROFS", EROFS, "Read-only file system");\r
-#endif\r
-#ifdef EADDRNOTAVAIL\r
-    inscode(d, ds, de, "EADDRNOTAVAIL", EADDRNOTAVAIL, "Cannot assign requested address");\r
-#else\r
-#ifdef WSAEADDRNOTAVAIL\r
-    inscode(d, ds, de, "EADDRNOTAVAIL", WSAEADDRNOTAVAIL, "Cannot assign requested address");\r
-#endif\r
-#endif\r
-#ifdef EIDRM\r
-    inscode(d, ds, de, "EIDRM", EIDRM, "Identifier removed");\r
-#endif\r
-#ifdef ECOMM\r
-    inscode(d, ds, de, "ECOMM", ECOMM, "Communication error on send");\r
-#endif\r
-#ifdef ESRMNT\r
-    inscode(d, ds, de, "ESRMNT", ESRMNT, "Srmount error");\r
-#endif\r
-#ifdef EREMOTEIO\r
-    inscode(d, ds, de, "EREMOTEIO", EREMOTEIO, "Remote I/O error");\r
-#endif\r
-#ifdef EL3RST\r
-    inscode(d, ds, de, "EL3RST", EL3RST, "Level 3 reset");\r
-#endif\r
-#ifdef EBADMSG\r
-    inscode(d, ds, de, "EBADMSG", EBADMSG, "Not a data message");\r
-#endif\r
-#ifdef ENFILE\r
-    inscode(d, ds, de, "ENFILE", ENFILE, "File table overflow");\r
-#endif\r
-#ifdef ELIBMAX\r
-    inscode(d, ds, de, "ELIBMAX", ELIBMAX, "Attempting to link in too many shared libraries");\r
-#endif\r
-#ifdef ESPIPE\r
-    inscode(d, ds, de, "ESPIPE", ESPIPE, "Illegal seek");\r
-#endif\r
-#ifdef ENOLINK\r
-    inscode(d, ds, de, "ENOLINK", ENOLINK, "Link has been severed");\r
-#endif\r
-#ifdef ENETRESET\r
-    inscode(d, ds, de, "ENETRESET", ENETRESET, "Network dropped connection because of reset");\r
-#else\r
-#ifdef WSAENETRESET\r
-    inscode(d, ds, de, "ENETRESET", WSAENETRESET, "Network dropped connection because of reset");\r
-#endif\r
-#endif\r
-#ifdef ETIMEDOUT\r
-    inscode(d, ds, de, "ETIMEDOUT", ETIMEDOUT, "Connection timed out");\r
-#else\r
-#ifdef WSAETIMEDOUT\r
-    inscode(d, ds, de, "ETIMEDOUT", WSAETIMEDOUT, "Connection timed out");\r
-#endif\r
-#endif\r
-#ifdef ENOENT\r
-    inscode(d, ds, de, "ENOENT", ENOENT, "No such file or directory");\r
-#endif\r
-#ifdef EEXIST\r
-    inscode(d, ds, de, "EEXIST", EEXIST, "File exists");\r
-#endif\r
-#ifdef EDQUOT\r
-    inscode(d, ds, de, "EDQUOT", EDQUOT, "Quota exceeded");\r
-#else\r
-#ifdef WSAEDQUOT\r
-    inscode(d, ds, de, "EDQUOT", WSAEDQUOT, "Quota exceeded");\r
-#endif\r
-#endif\r
-#ifdef ENOSTR\r
-    inscode(d, ds, de, "ENOSTR", ENOSTR, "Device not a stream");\r
-#endif\r
-#ifdef EBADSLT\r
-    inscode(d, ds, de, "EBADSLT", EBADSLT, "Invalid slot");\r
-#endif\r
-#ifdef EBADRQC\r
-    inscode(d, ds, de, "EBADRQC", EBADRQC, "Invalid request code");\r
-#endif\r
-#ifdef ELIBACC\r
-    inscode(d, ds, de, "ELIBACC", ELIBACC, "Can not access a needed shared library");\r
-#endif\r
-#ifdef EFAULT\r
-    inscode(d, ds, de, "EFAULT", EFAULT, "Bad address");\r
-#else\r
-#ifdef WSAEFAULT\r
-    inscode(d, ds, de, "EFAULT", WSAEFAULT, "Bad address");\r
-#endif\r
-#endif\r
-#ifdef EFBIG\r
-    inscode(d, ds, de, "EFBIG", EFBIG, "File too large");\r
-#endif\r
-#ifdef EDEADLK\r
-    inscode(d, ds, de, "EDEADLK", EDEADLK, "Resource deadlock would occur");\r
-#endif\r
-#ifdef ENOTCONN\r
-    inscode(d, ds, de, "ENOTCONN", ENOTCONN, "Transport endpoint is not connected");\r
-#else\r
-#ifdef WSAENOTCONN\r
-    inscode(d, ds, de, "ENOTCONN", WSAENOTCONN, "Transport endpoint is not connected");\r
-#endif\r
-#endif\r
-#ifdef EDESTADDRREQ\r
-    inscode(d, ds, de, "EDESTADDRREQ", EDESTADDRREQ, "Destination address required");\r
-#else\r
-#ifdef WSAEDESTADDRREQ\r
-    inscode(d, ds, de, "EDESTADDRREQ", WSAEDESTADDRREQ, "Destination address required");\r
-#endif\r
-#endif\r
-#ifdef ELIBSCN\r
-    inscode(d, ds, de, "ELIBSCN", ELIBSCN, ".lib section in a.out corrupted");\r
-#endif\r
-#ifdef ENOLCK\r
-    inscode(d, ds, de, "ENOLCK", ENOLCK, "No record locks available");\r
-#endif\r
-#ifdef EISNAM\r
-    inscode(d, ds, de, "EISNAM", EISNAM, "Is a named type file");\r
-#endif\r
-#ifdef ECONNABORTED\r
-    inscode(d, ds, de, "ECONNABORTED", ECONNABORTED, "Software caused connection abort");\r
-#else\r
-#ifdef WSAECONNABORTED\r
-    inscode(d, ds, de, "ECONNABORTED", WSAECONNABORTED, "Software caused connection abort");\r
-#endif\r
-#endif\r
-#ifdef ENETUNREACH\r
-    inscode(d, ds, de, "ENETUNREACH", ENETUNREACH, "Network is unreachable");\r
-#else\r
-#ifdef WSAENETUNREACH\r
-    inscode(d, ds, de, "ENETUNREACH", WSAENETUNREACH, "Network is unreachable");\r
-#endif\r
-#endif\r
-#ifdef ESTALE\r
-    inscode(d, ds, de, "ESTALE", ESTALE, "Stale NFS file handle");\r
-#else\r
-#ifdef WSAESTALE\r
-    inscode(d, ds, de, "ESTALE", WSAESTALE, "Stale NFS file handle");\r
-#endif\r
-#endif\r
-#ifdef ENOSR\r
-    inscode(d, ds, de, "ENOSR", ENOSR, "Out of streams resources");\r
-#endif\r
-#ifdef ENOMEM\r
-    inscode(d, ds, de, "ENOMEM", ENOMEM, "Out of memory");\r
-#endif\r
-#ifdef ENOTSOCK\r
-    inscode(d, ds, de, "ENOTSOCK", ENOTSOCK, "Socket operation on non-socket");\r
-#else\r
-#ifdef WSAENOTSOCK\r
-    inscode(d, ds, de, "ENOTSOCK", WSAENOTSOCK, "Socket operation on non-socket");\r
-#endif\r
-#endif\r
-#ifdef ESTRPIPE\r
-    inscode(d, ds, de, "ESTRPIPE", ESTRPIPE, "Streams pipe error");\r
-#endif\r
-#ifdef EMLINK\r
-    inscode(d, ds, de, "EMLINK", EMLINK, "Too many links");\r
-#endif\r
-#ifdef ERANGE\r
-    inscode(d, ds, de, "ERANGE", ERANGE, "Math result not representable");\r
-#endif\r
-#ifdef ELIBEXEC\r
-    inscode(d, ds, de, "ELIBEXEC", ELIBEXEC, "Cannot exec a shared library directly");\r
-#endif\r
-#ifdef EL3HLT\r
-    inscode(d, ds, de, "EL3HLT", EL3HLT, "Level 3 halted");\r
-#endif\r
-#ifdef ECONNRESET\r
-    inscode(d, ds, de, "ECONNRESET", ECONNRESET, "Connection reset by peer");\r
-#else\r
-#ifdef WSAECONNRESET\r
-    inscode(d, ds, de, "ECONNRESET", WSAECONNRESET, "Connection reset by peer");\r
-#endif\r
-#endif\r
-#ifdef EADDRINUSE\r
-    inscode(d, ds, de, "EADDRINUSE", EADDRINUSE, "Address already in use");\r
-#else\r
-#ifdef WSAEADDRINUSE\r
-    inscode(d, ds, de, "EADDRINUSE", WSAEADDRINUSE, "Address already in use");\r
-#endif\r
-#endif\r
-#ifdef EOPNOTSUPP\r
-    inscode(d, ds, de, "EOPNOTSUPP", EOPNOTSUPP, "Operation not supported on transport endpoint");\r
-#else\r
-#ifdef WSAEOPNOTSUPP\r
-    inscode(d, ds, de, "EOPNOTSUPP", WSAEOPNOTSUPP, "Operation not supported on transport endpoint");\r
-#endif\r
-#endif\r
-#ifdef EREMCHG\r
-    inscode(d, ds, de, "EREMCHG", EREMCHG, "Remote address changed");\r
-#endif\r
-#ifdef EAGAIN\r
-    inscode(d, ds, de, "EAGAIN", EAGAIN, "Try again");\r
-#endif\r
-#ifdef ENAMETOOLONG\r
-    inscode(d, ds, de, "ENAMETOOLONG", ENAMETOOLONG, "File name too long");\r
-#else\r
-#ifdef WSAENAMETOOLONG\r
-    inscode(d, ds, de, "ENAMETOOLONG", WSAENAMETOOLONG, "File name too long");\r
-#endif\r
-#endif\r
-#ifdef ENOTTY\r
-    inscode(d, ds, de, "ENOTTY", ENOTTY, "Not a typewriter");\r
-#endif\r
-#ifdef ERESTART\r
-    inscode(d, ds, de, "ERESTART", ERESTART, "Interrupted system call should be restarted");\r
-#endif\r
-#ifdef ESOCKTNOSUPPORT\r
-    inscode(d, ds, de, "ESOCKTNOSUPPORT", ESOCKTNOSUPPORT, "Socket type not supported");\r
-#else\r
-#ifdef WSAESOCKTNOSUPPORT\r
-    inscode(d, ds, de, "ESOCKTNOSUPPORT", WSAESOCKTNOSUPPORT, "Socket type not supported");\r
-#endif\r
-#endif\r
-#ifdef ETIME\r
-    inscode(d, ds, de, "ETIME", ETIME, "Timer expired");\r
-#endif\r
-#ifdef EBFONT\r
-    inscode(d, ds, de, "EBFONT", EBFONT, "Bad font file format");\r
-#endif\r
-#ifdef EDEADLOCK\r
-    inscode(d, ds, de, "EDEADLOCK", EDEADLOCK, "Error EDEADLOCK");\r
-#endif\r
-#ifdef ETOOMANYREFS\r
-    inscode(d, ds, de, "ETOOMANYREFS", ETOOMANYREFS, "Too many references: cannot splice");\r
-#else\r
-#ifdef WSAETOOMANYREFS\r
-    inscode(d, ds, de, "ETOOMANYREFS", WSAETOOMANYREFS, "Too many references: cannot splice");\r
-#endif\r
-#endif\r
-#ifdef EMFILE\r
-    inscode(d, ds, de, "EMFILE", EMFILE, "Too many open files");\r
-#else\r
-#ifdef WSAEMFILE\r
-    inscode(d, ds, de, "EMFILE", WSAEMFILE, "Too many open files");\r
-#endif\r
-#endif\r
-#ifdef ETXTBSY\r
-    inscode(d, ds, de, "ETXTBSY", ETXTBSY, "Text file busy");\r
-#endif\r
-#ifdef EINPROGRESS\r
-    inscode(d, ds, de, "EINPROGRESS", EINPROGRESS, "Operation now in progress");\r
-#else\r
-#ifdef WSAEINPROGRESS\r
-    inscode(d, ds, de, "EINPROGRESS", WSAEINPROGRESS, "Operation now in progress");\r
-#endif\r
-#endif\r
-#ifdef ENXIO\r
-    inscode(d, ds, de, "ENXIO", ENXIO, "No such device or address");\r
-#endif\r
-#ifdef ENOPKG\r
-    inscode(d, ds, de, "ENOPKG", ENOPKG, "Package not installed");\r
-#endif\r
-#ifdef WSASY\r
-    inscode(d, ds, de, "WSASY", WSASY, "Error WSASY");\r
-#endif\r
-#ifdef WSAEHOSTDOWN\r
-    inscode(d, ds, de, "WSAEHOSTDOWN", WSAEHOSTDOWN, "Host is down");\r
-#endif\r
-#ifdef WSAENETDOWN\r
-    inscode(d, ds, de, "WSAENETDOWN", WSAENETDOWN, "Network is down");\r
-#endif\r
-#ifdef WSAENOTSOCK\r
-    inscode(d, ds, de, "WSAENOTSOCK", WSAENOTSOCK, "Socket operation on non-socket");\r
-#endif\r
-#ifdef WSAEHOSTUNREACH\r
-    inscode(d, ds, de, "WSAEHOSTUNREACH", WSAEHOSTUNREACH, "No route to host");\r
-#endif\r
-#ifdef WSAELOOP\r
-    inscode(d, ds, de, "WSAELOOP", WSAELOOP, "Too many symbolic links encountered");\r
-#endif\r
-#ifdef WSAEMFILE\r
-    inscode(d, ds, de, "WSAEMFILE", WSAEMFILE, "Too many open files");\r
-#endif\r
-#ifdef WSAESTALE\r
-    inscode(d, ds, de, "WSAESTALE", WSAESTALE, "Stale NFS file handle");\r
-#endif\r
-#ifdef WSAVERNOTSUPPORTED\r
-    inscode(d, ds, de, "WSAVERNOTSUPPORTED", WSAVERNOTSUPPORTED, "Error WSAVERNOTSUPPORTED");\r
-#endif\r
-#ifdef WSAENETUNREACH\r
-    inscode(d, ds, de, "WSAENETUNREACH", WSAENETUNREACH, "Network is unreachable");\r
-#endif\r
-#ifdef WSAEPROCLIM\r
-    inscode(d, ds, de, "WSAEPROCLIM", WSAEPROCLIM, "Error WSAEPROCLIM");\r
-#endif\r
-#ifdef WSAEFAULT\r
-    inscode(d, ds, de, "WSAEFAULT", WSAEFAULT, "Bad address");\r
-#endif\r
-#ifdef WSANOTINITIALISED\r
-    inscode(d, ds, de, "WSANOTINITIALISED", WSANOTINITIALISED, "Error WSANOTINITIALISED");\r
-#endif\r
-#ifdef WSAEUSERS\r
-    inscode(d, ds, de, "WSAEUSERS", WSAEUSERS, "Too many users");\r
-#endif\r
-#ifdef WSAMAKEASYNCREPL\r
-    inscode(d, ds, de, "WSAMAKEASYNCREPL", WSAMAKEASYNCREPL, "Error WSAMAKEASYNCREPL");\r
-#endif\r
-#ifdef WSAENOPROTOOPT\r
-    inscode(d, ds, de, "WSAENOPROTOOPT", WSAENOPROTOOPT, "Protocol not available");\r
-#endif\r
-#ifdef WSAECONNABORTED\r
-    inscode(d, ds, de, "WSAECONNABORTED", WSAECONNABORTED, "Software caused connection abort");\r
-#endif\r
-#ifdef WSAENAMETOOLONG\r
-    inscode(d, ds, de, "WSAENAMETOOLONG", WSAENAMETOOLONG, "File name too long");\r
-#endif\r
-#ifdef WSAENOTEMPTY\r
-    inscode(d, ds, de, "WSAENOTEMPTY", WSAENOTEMPTY, "Directory not empty");\r
-#endif\r
-#ifdef WSAESHUTDOWN\r
-    inscode(d, ds, de, "WSAESHUTDOWN", WSAESHUTDOWN, "Cannot send after transport endpoint shutdown");\r
-#endif\r
-#ifdef WSAEAFNOSUPPORT\r
-    inscode(d, ds, de, "WSAEAFNOSUPPORT", WSAEAFNOSUPPORT, "Address family not supported by protocol");\r
-#endif\r
-#ifdef WSAETOOMANYREFS\r
-    inscode(d, ds, de, "WSAETOOMANYREFS", WSAETOOMANYREFS, "Too many references: cannot splice");\r
-#endif\r
-#ifdef WSAEACCES\r
-    inscode(d, ds, de, "WSAEACCES", WSAEACCES, "Permission denied");\r
-#endif\r
-#ifdef WSATR\r
-    inscode(d, ds, de, "WSATR", WSATR, "Error WSATR");\r
-#endif\r
-#ifdef WSABASEERR\r
-    inscode(d, ds, de, "WSABASEERR", WSABASEERR, "Error WSABASEERR");\r
-#endif\r
-#ifdef WSADESCRIPTIO\r
-    inscode(d, ds, de, "WSADESCRIPTIO", WSADESCRIPTIO, "Error WSADESCRIPTIO");\r
-#endif\r
-#ifdef WSAEMSGSIZE\r
-    inscode(d, ds, de, "WSAEMSGSIZE", WSAEMSGSIZE, "Message too long");\r
-#endif\r
-#ifdef WSAEBADF\r
-    inscode(d, ds, de, "WSAEBADF", WSAEBADF, "Bad file number");\r
-#endif\r
-#ifdef WSAECONNRESET\r
-    inscode(d, ds, de, "WSAECONNRESET", WSAECONNRESET, "Connection reset by peer");\r
-#endif\r
-#ifdef WSAGETSELECTERRO\r
-    inscode(d, ds, de, "WSAGETSELECTERRO", WSAGETSELECTERRO, "Error WSAGETSELECTERRO");\r
-#endif\r
-#ifdef WSAETIMEDOUT\r
-    inscode(d, ds, de, "WSAETIMEDOUT", WSAETIMEDOUT, "Connection timed out");\r
-#endif\r
-#ifdef WSAENOBUFS\r
-    inscode(d, ds, de, "WSAENOBUFS", WSAENOBUFS, "No buffer space available");\r
-#endif\r
-#ifdef WSAEDISCON\r
-    inscode(d, ds, de, "WSAEDISCON", WSAEDISCON, "Error WSAEDISCON");\r
-#endif\r
-#ifdef WSAEINTR\r
-    inscode(d, ds, de, "WSAEINTR", WSAEINTR, "Interrupted system call");\r
-#endif\r
-#ifdef WSAEPROTOTYPE\r
-    inscode(d, ds, de, "WSAEPROTOTYPE", WSAEPROTOTYPE, "Protocol wrong type for socket");\r
-#endif\r
-#ifdef WSAHOS\r
-    inscode(d, ds, de, "WSAHOS", WSAHOS, "Error WSAHOS");\r
-#endif\r
-#ifdef WSAEADDRINUSE\r
-    inscode(d, ds, de, "WSAEADDRINUSE", WSAEADDRINUSE, "Address already in use");\r
-#endif\r
-#ifdef WSAEADDRNOTAVAIL\r
-    inscode(d, ds, de, "WSAEADDRNOTAVAIL", WSAEADDRNOTAVAIL, "Cannot assign requested address");\r
-#endif\r
-#ifdef WSAEALREADY\r
-    inscode(d, ds, de, "WSAEALREADY", WSAEALREADY, "Operation already in progress");\r
-#endif\r
-#ifdef WSAEPROTONOSUPPORT\r
-    inscode(d, ds, de, "WSAEPROTONOSUPPORT", WSAEPROTONOSUPPORT, "Protocol not supported");\r
-#endif\r
-#ifdef WSASYSNOTREADY\r
-    inscode(d, ds, de, "WSASYSNOTREADY", WSASYSNOTREADY, "Error WSASYSNOTREADY");\r
-#endif\r
-#ifdef WSAEWOULDBLOCK\r
-    inscode(d, ds, de, "WSAEWOULDBLOCK", WSAEWOULDBLOCK, "Operation would block");\r
-#endif\r
-#ifdef WSAEPFNOSUPPORT\r
-    inscode(d, ds, de, "WSAEPFNOSUPPORT", WSAEPFNOSUPPORT, "Protocol family not supported");\r
-#endif\r
-#ifdef WSAEOPNOTSUPP\r
-    inscode(d, ds, de, "WSAEOPNOTSUPP", WSAEOPNOTSUPP, "Operation not supported on transport endpoint");\r
-#endif\r
-#ifdef WSAEISCONN\r
-    inscode(d, ds, de, "WSAEISCONN", WSAEISCONN, "Transport endpoint is already connected");\r
-#endif\r
-#ifdef WSAEDQUOT\r
-    inscode(d, ds, de, "WSAEDQUOT", WSAEDQUOT, "Quota exceeded");\r
-#endif\r
-#ifdef WSAENOTCONN\r
-    inscode(d, ds, de, "WSAENOTCONN", WSAENOTCONN, "Transport endpoint is not connected");\r
-#endif\r
-#ifdef WSAEREMOTE\r
-    inscode(d, ds, de, "WSAEREMOTE", WSAEREMOTE, "Object is remote");\r
-#endif\r
-#ifdef WSAEINVAL\r
-    inscode(d, ds, de, "WSAEINVAL", WSAEINVAL, "Invalid argument");\r
-#endif\r
-#ifdef WSAEINPROGRESS\r
-    inscode(d, ds, de, "WSAEINPROGRESS", WSAEINPROGRESS, "Operation now in progress");\r
-#endif\r
-#ifdef WSAGETSELECTEVEN\r
-    inscode(d, ds, de, "WSAGETSELECTEVEN", WSAGETSELECTEVEN, "Error WSAGETSELECTEVEN");\r
-#endif\r
-#ifdef WSAESOCKTNOSUPPORT\r
-    inscode(d, ds, de, "WSAESOCKTNOSUPPORT", WSAESOCKTNOSUPPORT, "Socket type not supported");\r
-#endif\r
-#ifdef WSAGETASYNCERRO\r
-    inscode(d, ds, de, "WSAGETASYNCERRO", WSAGETASYNCERRO, "Error WSAGETASYNCERRO");\r
-#endif\r
-#ifdef WSAMAKESELECTREPL\r
-    inscode(d, ds, de, "WSAMAKESELECTREPL", WSAMAKESELECTREPL, "Error WSAMAKESELECTREPL");\r
-#endif\r
-#ifdef WSAGETASYNCBUFLE\r
-    inscode(d, ds, de, "WSAGETASYNCBUFLE", WSAGETASYNCBUFLE, "Error WSAGETASYNCBUFLE");\r
-#endif\r
-#ifdef WSAEDESTADDRREQ\r
-    inscode(d, ds, de, "WSAEDESTADDRREQ", WSAEDESTADDRREQ, "Destination address required");\r
-#endif\r
-#ifdef WSAECONNREFUSED\r
-    inscode(d, ds, de, "WSAECONNREFUSED", WSAECONNREFUSED, "Connection refused");\r
-#endif\r
-#ifdef WSAENETRESET\r
-    inscode(d, ds, de, "WSAENETRESET", WSAENETRESET, "Network dropped connection because of reset");\r
-#endif\r
-#ifdef WSAN\r
-    inscode(d, ds, de, "WSAN", WSAN, "Error WSAN");\r
-#endif\r
-\r
-/* These symbols are added for EDK II support.  */\r
-#ifdef EMINERRORVAL\r
-  inscode(d, ds, de, "EMINERRORVAL", EMINERRORVAL, "Lowest valid error value");\r
-#endif\r
-#ifdef ENOTSUP\r
-  inscode(d, ds, de, "ENOTSUP", ENOTSUP, "Operation not supported");\r
-#endif\r
-#ifdef EBADRPC\r
-  inscode(d, ds, de, "EBADRPC", EBADRPC, "RPC struct is bad");\r
-#endif\r
-#ifdef ERPCMISMATCH\r
-  inscode(d, ds, de, "ERPCMISMATCH", ERPCMISMATCH, "RPC version wrong");\r
-#endif\r
-#ifdef EPROGUNAVAIL\r
-  inscode(d, ds, de, "EPROGUNAVAIL", EPROGUNAVAIL, "RPC prog. not avail");\r
-#endif\r
-#ifdef EPROGMISMATCH\r
-  inscode(d, ds, de, "EPROGMISMATCH", EPROGMISMATCH, "Program version wrong");\r
-#endif\r
-#ifdef EPROCUNAVAIL\r
-  inscode(d, ds, de, "EPROCUNAVAIL", EPROCUNAVAIL, "Bad procedure for program");\r
-#endif\r
-#ifdef EFTYPE\r
-  inscode(d, ds, de, "EFTYPE", EFTYPE, "Inappropriate file type or format");\r
-#endif\r
-#ifdef EAUTH\r
-  inscode(d, ds, de, "EAUTH", EAUTH, "Authentication error");\r
-#endif\r
-#ifdef ENEEDAUTH\r
-  inscode(d, ds, de, "ENEEDAUTH", ENEEDAUTH, "Need authenticator");\r
-#endif\r
-#ifdef ECANCELED\r
-  inscode(d, ds, de, "ECANCELED", ECANCELED, "Operation canceled");\r
-#endif\r
-#ifdef ENOATTR\r
-  inscode(d, ds, de, "ENOATTR", ENOATTR, "Attribute not found");\r
-#endif\r
-#ifdef EDOOFUS\r
-  inscode(d, ds, de, "EDOOFUS", EDOOFUS, "Programming Error");\r
-#endif\r
-#ifdef EBUFSIZE\r
-  inscode(d, ds, de, "EBUFSIZE", EBUFSIZE, "Buffer too small to hold result");\r
-#endif\r
-#ifdef EMAXERRORVAL\r
-  inscode(d, ds, de, "EMAXERRORVAL", EMAXERRORVAL, "One more than the highest defined error value");\r
-#endif\r
-\r
-    Py_DECREF(de);\r
-}\r