Mercurial > hg > octave-lojdl > gnulib-hg
changeset 11626:e54d8a239545
Define missing ESTALE on Interix 3.5.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Wed, 17 Jun 2009 10:37:33 +0200 |
parents | dfac57b1ec9f |
children | 50a064e9971c |
files | ChangeLog doc/posix-headers/errno.texi lib/errno.in.h lib/strerror.c m4/errno_h.m4 |
diffstat | 5 files changed, 32 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2009-06-17 Bruno Haible <bruno@clisp.org> + + Define missing ESTALE on Interix 3.5. + * lib/errno.in.h (ESTALE): Assign a value if missing. + * lib/strerror.c (rpl_strerror): Handle missing ESTALE and ECANCELED. + * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether ESTALE is + missing. + * doc/posix-headers/errno.texi: Mention the Interix bug. + Reported by Jay Krell <jay.krell@cornell.edu> via Eric Blake. + 2009-06-15 Eric Blake <ebb9@byu.net> memchr, memchr2: add valgrind exception
--- a/doc/posix-headers/errno.texi +++ b/doc/posix-headers/errno.texi @@ -19,14 +19,17 @@ @code{ENOTSUP} are not defined on some platforms: OpenBSD 4.0, mingw. @item +The macro @code{ESTALE} is not defined on some platforms: +mingw, Interix 3.5. +@item The macros @code{EWOULDBLOCK}, @code{ETXTBSY}, @code{ELOOP}, @code{ENOTSOCK}, @code{EDESTADDRREQ}, @code{EMSGSIZE}, @code{EPROTOTYPE}, @code{ENOPROTOOPT}, @code{EPROTONOSUPPORT}, @code{EOPNOTSUPP}, @code{EAFNOSUPPORT}, @code{EADDRINUSE}, @code{EADDRNOTAVAIL}, @code{ENETDOWN}, @code{ENETUNREACH}, @code{ENETRESET}, @code{ECONNABORTED}, @code{ECONNRESET}, @code{ENOBUFS}, @code{EISCONN}, @code{ENOTCONN}, @code{ETIMEDOUT}, @code{ECONNREFUSED}, -@code{EHOSTUNREACH}, @code{EALREADY}, @code{EINPROGRESS}, @code{ESTALE}, -@code{EDQUOT} are not defined on some platforms: +@code{EHOSTUNREACH}, @code{EALREADY}, @code{EINPROGRESS}, @code{EDQUOT} are +not defined on some platforms: mingw. @end itemize
--- a/lib/errno.in.h +++ b/lib/errno.in.h @@ -1,6 +1,6 @@ /* A POSIX-like <errno.h>. - Copyright (C) 2008 Free Software Foundation, Inc. + Copyright (C) 2008-2009 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -145,6 +145,11 @@ # define GNULIB_defined_ENOTSUP 1 # endif +# ifndef ESTALE +# define ESTALE 2009 +# define GNULIB_defined_ESTALE 1 +# endif + # ifndef ECANCELED # define ECANCELED 2008 # define GNULIB_defined_ECANCELED 1
--- a/lib/strerror.c +++ b/lib/strerror.c @@ -313,7 +313,13 @@ break; # endif -# if GNULIB_defined_ +# if GNULIB_defined_ESTALE + case ESTALE: + msg = "Stale NFS file handle"; + break; +# endif + +# if GNULIB_defined_ECANCELED case ECANCELED: msg = "Operation canceled"; break;
--- a/m4/errno_h.m4 +++ b/m4/errno_h.m4 @@ -1,4 +1,4 @@ -# errno_h.m4 serial 5 +# errno_h.m4 serial 6 dnl Copyright (C) 2004, 2006, 2008, 2009 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -34,6 +34,9 @@ #if !defined ENOTSUP booboo #endif +#if !defined ESTALE +booboo +#endif #if !defined ECANCELED booboo #endif