X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Ffstatat.c;h=b217126beb11f677d6fa981bda014b6889c92588;hb=0e37faa962c9da84e85e24f409c2ff3836ba28d6;hp=d58e60b8a4c69d24f4a24511dd8224a7bfaa3fc5;hpb=441aa3044f43e5572f58c354f01e6bc070acd5c7;p=gnulib.git diff --git a/lib/fstatat.c b/lib/fstatat.c index d58e60b8a..b217126be 100644 --- a/lib/fstatat.c +++ b/lib/fstatat.c @@ -1,6 +1,6 @@ /* Work around an fstatat bug on Solaris 9. - Copyright (C) 2006, 2009 Free Software Foundation, Inc. + Copyright (C) 2006, 2009-2011 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 @@ -25,7 +25,7 @@ #include #include -#if HAVE_FSTATAT +#if HAVE_FSTATAT && ! FSTATAT_ST_SIZE_ETC_BROKEN # undef fstatat @@ -65,7 +65,12 @@ rpl_fstatat (int fd, char const *file, struct stat *st, int flag) return result; } -#else /* !HAVE_FSTATAT */ +#else /* ! (HAVE_FSTATAT && ! FSTATAT_ST_SIZE_ETC_BROKEN) */ + +# if HAVE_FSTATAT +# undef fstatat +# define fstatat rpl_fstatat +# endif /* On mingw, the gnulib defines `stat' as a function-like macro; but using it in AT_FUNC_F2 causes compilation failure @@ -107,4 +112,4 @@ stat_func (char const *name, struct stat *st) # undef AT_FUNC_POST_FILE_PARAM_DECLS # undef AT_FUNC_POST_FILE_ARGS -#endif /* !HAVE_FSTATAT */ +#endif /* ! (HAVE_FSTATAT && ! FSTATAT_ST_SIZE_ETC_BROKEN) */