Mercurial > hg > octave-lojdl > gnulib-hg
changeset 12584:87284d3e1be2
stdio, unistd: guarantee ssize_t
Per POSIX 2008, ssize_t needs to exist whether or not we are
replacing functions that use it. For now, we only guarantee
it if we know that the user expects a function that uses
that type, while waiting for glibc to catch up to POSIX.
* lib/unistd.in.h (includes): Ensure that types required by POSIX
2008 are exposed when needed.
* lib/stdio.in.h (includes): Likewise.
Reported by Ralf Wildenhues.
Signed-off-by: Eric Blake <ebb9@byu.net>
author | Eric Blake <ebb9@byu.net> |
---|---|
date | Wed, 06 Jan 2010 07:09:03 -0700 |
parents | 462199e08415 |
children | 6e2f4ea77ab4 |
files | ChangeLog lib/stdio.in.h lib/unistd.in.h |
diffstat | 3 files changed, 12 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2010-01-06 Eric Blake <ebb9@byu.net> + + stdio, unistd: guarantee ssize_t + * lib/unistd.in.h (includes): Ensure that types required by POSIX + 2008 are exposed when needed. + * lib/stdio.in.h (includes): Likewise. + Reported by Ralf Wildenhues. + 2010-01-06 Paolo Bonzini <bonzini@gnu.org> nl_langinfo: do not call AC_CHECK_FUNC_ONCE inside if.
--- a/lib/stdio.in.h +++ b/lib/stdio.in.h @@ -39,11 +39,8 @@ #include <stdarg.h> #include <stddef.h> -#if ((@GNULIB_FSEEKO@ && @REPLACE_FSEEKO@) \ - || (@GNULIB_FTELLO@ && @REPLACE_FTELLO@) \ - || (@GNULIB_GETDELIM@ && !@HAVE_DECL_GETDELIM@) \ - || (@GNULIB_GETLINE@ && (!@HAVE_DECL_GETLINE@ || @REPLACE_GETLINE@)) \ - || defined GNULIB_POSIXCHECK) +#if (@GNULIB_FSEEKO@ || @GNULIB_FTELLO@ || @GNULIB_GETDELIM@ \ + || @GNULIB_GETLINE@ || defined GNULIB_POSIXCHECK) /* Get off_t and ssize_t. */ # include <sys/types.h> #endif
--- a/lib/unistd.in.h +++ b/lib/unistd.in.h @@ -61,10 +61,8 @@ # include <io.h> #endif -#if ((@GNULIB_WRITE@ && @REPLACE_WRITE@ && @GNULIB_UNISTD_H_SIGPIPE@) \ - || (@GNULIB_READLINK@ && (!@HAVE_READLINK@ || @REPLACE_READLINK@)) \ - || (@GNULIB_READLINKAT@ && !@HAVE_READLINKAT@) \ - || defined GNULIB_POSIXCHECK) +#if (@GNULIB_WRITE@ || @GNULIB_READLINK@ || @GNULIB_READLINKAT@ \ + || @GNULIB_PREAD@ || defined GNULIB_POSIXCHECK) /* Get ssize_t. */ # include <sys/types.h> #endif