Blame lib/errno.in.h

Packit 709fb3
/* A POSIX-like <errno.h>.
Packit 709fb3
Packit 709fb3
   Copyright (C) 2008-2017 Free Software Foundation, Inc.
Packit 709fb3
Packit 709fb3
   This program is free software; you can redistribute it and/or modify
Packit 709fb3
   it under the terms of the GNU General Public License as published by
Packit 709fb3
   the Free Software Foundation; either version 3, or (at your option)
Packit 709fb3
   any later version.
Packit 709fb3
Packit 709fb3
   This program is distributed in the hope that it will be useful,
Packit 709fb3
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 709fb3
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit 709fb3
   GNU General Public License for more details.
Packit 709fb3
Packit 709fb3
   You should have received a copy of the GNU General Public License
Packit 709fb3
   along with this program; if not, see <http://www.gnu.org/licenses/>.  */
Packit 709fb3
Packit 709fb3
#ifndef _@GUARD_PREFIX@_ERRNO_H
Packit 709fb3
Packit 709fb3
#if __GNUC__ >= 3
Packit 709fb3
@PRAGMA_SYSTEM_HEADER@
Packit 709fb3
#endif
Packit 709fb3
@PRAGMA_COLUMNS@
Packit 709fb3
Packit 709fb3
/* The include_next requires a split double-inclusion guard.  */
Packit 709fb3
#@INCLUDE_NEXT@ @NEXT_ERRNO_H@
Packit 709fb3
Packit 709fb3
#ifndef _@GUARD_PREFIX@_ERRNO_H
Packit 709fb3
#define _@GUARD_PREFIX@_ERRNO_H
Packit 709fb3
Packit 709fb3
Packit 709fb3
/* On native Windows platforms, many macros are not defined.  */
Packit 709fb3
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
Packit 709fb3
Packit 709fb3
/* These are the same values as defined by MSVC 10, for interoperability.  */
Packit 709fb3
Packit 709fb3
#  ifndef ENOMSG
Packit 709fb3
#   define ENOMSG    122
Packit 709fb3
#   define GNULIB_defined_ENOMSG 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EIDRM
Packit 709fb3
#   define EIDRM     111
Packit 709fb3
#   define GNULIB_defined_EIDRM 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ENOLINK
Packit 709fb3
#   define ENOLINK   121
Packit 709fb3
#   define GNULIB_defined_ENOLINK 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EPROTO
Packit 709fb3
#   define EPROTO    134
Packit 709fb3
#   define GNULIB_defined_EPROTO 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EBADMSG
Packit 709fb3
#   define EBADMSG   104
Packit 709fb3
#   define GNULIB_defined_EBADMSG 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EOVERFLOW
Packit 709fb3
#   define EOVERFLOW 132
Packit 709fb3
#   define GNULIB_defined_EOVERFLOW 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ENOTSUP
Packit 709fb3
#   define ENOTSUP   129
Packit 709fb3
#   define GNULIB_defined_ENOTSUP 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ENETRESET
Packit 709fb3
#   define ENETRESET 117
Packit 709fb3
#   define GNULIB_defined_ENETRESET 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ECONNABORTED
Packit 709fb3
#   define ECONNABORTED 106
Packit 709fb3
#   define GNULIB_defined_ECONNABORTED 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ECANCELED
Packit 709fb3
#   define ECANCELED 105
Packit 709fb3
#   define GNULIB_defined_ECANCELED 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EOWNERDEAD
Packit 709fb3
#   define EOWNERDEAD 133
Packit 709fb3
#   define GNULIB_defined_EOWNERDEAD 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ENOTRECOVERABLE
Packit 709fb3
#   define ENOTRECOVERABLE 127
Packit 709fb3
#   define GNULIB_defined_ENOTRECOVERABLE 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef EINPROGRESS
Packit 709fb3
#   define EINPROGRESS     112
Packit 709fb3
#   define EALREADY        103
Packit 709fb3
#   define ENOTSOCK        128
Packit 709fb3
#   define EDESTADDRREQ    109
Packit 709fb3
#   define EMSGSIZE        115
Packit 709fb3
#   define EPROTOTYPE      136
Packit 709fb3
#   define ENOPROTOOPT     123
Packit 709fb3
#   define EPROTONOSUPPORT 135
Packit 709fb3
#   define EOPNOTSUPP      130
Packit 709fb3
#   define EAFNOSUPPORT    102
Packit 709fb3
#   define EADDRINUSE      100
Packit 709fb3
#   define EADDRNOTAVAIL   101
Packit 709fb3
#   define ENETDOWN        116
Packit 709fb3
#   define ENETUNREACH     118
Packit 709fb3
#   define ECONNRESET      108
Packit 709fb3
#   define ENOBUFS         119
Packit 709fb3
#   define EISCONN         113
Packit 709fb3
#   define ENOTCONN        126
Packit 709fb3
#   define ETIMEDOUT       138
Packit 709fb3
#   define ECONNREFUSED    107
Packit 709fb3
#   define ELOOP           114
Packit 709fb3
#   define EHOSTUNREACH    110
Packit 709fb3
#   define EWOULDBLOCK     140
Packit 709fb3
#   define GNULIB_defined_ESOCK 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
#  ifndef ETXTBSY
Packit 709fb3
#   define ETXTBSY         139
Packit 709fb3
#   define ENODATA         120  /* not required by POSIX */
Packit 709fb3
#   define ENOSR           124  /* not required by POSIX */
Packit 709fb3
#   define ENOSTR          125  /* not required by POSIX */
Packit 709fb3
#   define ETIME           137  /* not required by POSIX */
Packit 709fb3
#   define EOTHER          131  /* not required by POSIX */
Packit 709fb3
#   define GNULIB_defined_ESTREAMS 1
Packit 709fb3
#  endif
Packit 709fb3
Packit 709fb3
/* These are intentionally the same values as the WSA* error numbers, defined
Packit 709fb3
   in <winsock2.h>.  */
Packit 709fb3
#  define ESOCKTNOSUPPORT 10044  /* not required by POSIX */
Packit 709fb3
#  define EPFNOSUPPORT    10046  /* not required by POSIX */
Packit 709fb3
#  define ESHUTDOWN       10058  /* not required by POSIX */
Packit 709fb3
#  define ETOOMANYREFS    10059  /* not required by POSIX */
Packit 709fb3
#  define EHOSTDOWN       10064  /* not required by POSIX */
Packit 709fb3
#  define EPROCLIM        10067  /* not required by POSIX */
Packit 709fb3
#  define EUSERS          10068  /* not required by POSIX */
Packit 709fb3
#  define EDQUOT          10069
Packit 709fb3
#  define ESTALE          10070
Packit 709fb3
#  define EREMOTE         10071  /* not required by POSIX */
Packit 709fb3
#  define GNULIB_defined_EWINSOCK 1
Packit 709fb3
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
Packit 709fb3
/* On OSF/1 5.1, when _XOPEN_SOURCE_EXTENDED is not defined, the macros
Packit 709fb3
   EMULTIHOP, ENOLINK, EOVERFLOW are not defined.  */
Packit 709fb3
# if @EMULTIHOP_HIDDEN@
Packit 709fb3
#  define EMULTIHOP @EMULTIHOP_VALUE@
Packit 709fb3
#  define GNULIB_defined_EMULTIHOP 1
Packit 709fb3
# endif
Packit 709fb3
# if @ENOLINK_HIDDEN@
Packit 709fb3
#  define ENOLINK   @ENOLINK_VALUE@
Packit 709fb3
#  define GNULIB_defined_ENOLINK 1
Packit 709fb3
# endif
Packit 709fb3
# if @EOVERFLOW_HIDDEN@
Packit 709fb3
#  define EOVERFLOW @EOVERFLOW_VALUE@
Packit 709fb3
#  define GNULIB_defined_EOVERFLOW 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
Packit 709fb3
/* On OpenBSD 4.0 and on native Windows, the macros ENOMSG, EIDRM, ENOLINK,
Packit 709fb3
   EPROTO, EMULTIHOP, EBADMSG, EOVERFLOW, ENOTSUP, ECANCELED are not defined.
Packit 709fb3
   Likewise, on NonStop Kernel, EDQUOT is not defined.
Packit 709fb3
   Define them here.  Values >= 2000 seem safe to use: Solaris ESTALE = 151,
Packit 709fb3
   HP-UX EWOULDBLOCK = 246, IRIX EDQUOT = 1133.
Packit 709fb3
Packit 709fb3
   Note: When one of these systems defines some of these macros some day,
Packit 709fb3
   binaries will have to be recompiled so that they recognizes the new
Packit 709fb3
   errno values from the system.  */
Packit 709fb3
Packit 709fb3
# ifndef ENOMSG
Packit 709fb3
#  define ENOMSG    2000
Packit 709fb3
#  define GNULIB_defined_ENOMSG 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EIDRM
Packit 709fb3
#  define EIDRM     2001
Packit 709fb3
#  define GNULIB_defined_EIDRM 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ENOLINK
Packit 709fb3
#  define ENOLINK   2002
Packit 709fb3
#  define GNULIB_defined_ENOLINK 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EPROTO
Packit 709fb3
#  define EPROTO    2003
Packit 709fb3
#  define GNULIB_defined_EPROTO 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EMULTIHOP
Packit 709fb3
#  define EMULTIHOP 2004
Packit 709fb3
#  define GNULIB_defined_EMULTIHOP 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EBADMSG
Packit 709fb3
#  define EBADMSG   2005
Packit 709fb3
#  define GNULIB_defined_EBADMSG 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EOVERFLOW
Packit 709fb3
#  define EOVERFLOW 2006
Packit 709fb3
#  define GNULIB_defined_EOVERFLOW 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ENOTSUP
Packit 709fb3
#  define ENOTSUP   2007
Packit 709fb3
#  define GNULIB_defined_ENOTSUP 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ENETRESET
Packit 709fb3
#  define ENETRESET 2011
Packit 709fb3
#  define GNULIB_defined_ENETRESET 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ECONNABORTED
Packit 709fb3
#  define ECONNABORTED 2012
Packit 709fb3
#  define GNULIB_defined_ECONNABORTED 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ESTALE
Packit 709fb3
#  define ESTALE    2009
Packit 709fb3
#  define GNULIB_defined_ESTALE 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EDQUOT
Packit 709fb3
#  define EDQUOT 2010
Packit 709fb3
#  define GNULIB_defined_EDQUOT 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef ECANCELED
Packit 709fb3
#  define ECANCELED 2008
Packit 709fb3
#  define GNULIB_defined_ECANCELED 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
/* On many platforms, the macros EOWNERDEAD and ENOTRECOVERABLE are not
Packit 709fb3
   defined.  */
Packit 709fb3
Packit 709fb3
# ifndef EOWNERDEAD
Packit 709fb3
#  if defined __sun
Packit 709fb3
    /* Use the same values as defined for Solaris >= 8, for
Packit 709fb3
       interoperability.  */
Packit 709fb3
#   define EOWNERDEAD      58
Packit 709fb3
#   define ENOTRECOVERABLE 59
Packit 709fb3
#  elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
Packit 709fb3
    /* We have a conflict here: pthreads-win32 defines these values
Packit 709fb3
       differently than MSVC 10.  It's hairy to decide which one to use.  */
Packit 709fb3
#   if defined __MINGW32__ && !defined USE_WINDOWS_THREADS
Packit 709fb3
     /* Use the same values as defined by pthreads-win32, for
Packit 709fb3
        interoperability.  */
Packit 709fb3
#    define EOWNERDEAD      43
Packit 709fb3
#    define ENOTRECOVERABLE 44
Packit 709fb3
#   else
Packit 709fb3
     /* Use the same values as defined by MSVC 10, for
Packit 709fb3
        interoperability.  */
Packit 709fb3
#    define EOWNERDEAD      133
Packit 709fb3
#    define ENOTRECOVERABLE 127
Packit 709fb3
#   endif
Packit 709fb3
#  else
Packit 709fb3
#   define EOWNERDEAD      2013
Packit 709fb3
#   define ENOTRECOVERABLE 2014
Packit 709fb3
#  endif
Packit 709fb3
#  define GNULIB_defined_EOWNERDEAD 1
Packit 709fb3
#  define GNULIB_defined_ENOTRECOVERABLE 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
# ifndef EILSEQ
Packit 709fb3
#  define EILSEQ 2015
Packit 709fb3
#  define GNULIB_defined_EILSEQ 1
Packit 709fb3
# endif
Packit 709fb3
Packit 709fb3
#endif /* _@GUARD_PREFIX@_ERRNO_H */
Packit 709fb3
#endif /* _@GUARD_PREFIX@_ERRNO_H */