Another removal of leftover code:
2017-05-13 Bruno Haible <br...@clisp.org> stat, fstat: Complete removal of old native Windows code. * lib/stat.c: Remove old macrology for WINDOWS_NATIVE. * lib/fstat.c: Likewise. * lib/stat-w32.c: Likewise. diff --git a/lib/fstat.c b/lib/fstat.c index 605ac7d..d2e0468 100644 --- a/lib/fstat.c +++ b/lib/fstat.c @@ -27,12 +27,6 @@ #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ # define WINDOWS_NATIVE -# if _GL_WINDOWS_64_BIT_ST_SIZE -# undef stat /* avoid warning on mingw64 with _FILE_OFFSET_BITS=64 */ -# define stat _stati64 -# undef fstat /* avoid warning on mingw64 with _FILE_OFFSET_BITS=64 */ -# define fstat _fstati64 -# endif #endif #if !defined WINDOWS_NATIVE diff --git a/lib/stat-w32.c b/lib/stat-w32.c index 4f4a105..4818a57 100644 --- a/lib/stat-w32.c +++ b/lib/stat-w32.c @@ -18,22 +18,19 @@ #include <config.h> +#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ + #include <sys/types.h> #include <sys/stat.h> -#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ -# if _GL_WINDOWS_64_BIT_ST_SIZE -# undef stat /* avoid warning on mingw64 with _FILE_OFFSET_BITS=64 */ -# define stat _stati64 -# endif -# include <errno.h> -# include <limits.h> -# include <unistd.h> -# include <windows.h> +#include <errno.h> +#include <limits.h> +#include <unistd.h> +#include <windows.h> /* Specification. */ -# include "stat-w32.h" +#include "stat-w32.h" -# include "pathmax.h" +#include "pathmax.h" /* GetFinalPathNameByHandle was introduced only in Windows Vista. */ typedef DWORD (WINAPI * GetFinalPathNameByHandleFuncType) (HANDLE hFile, diff --git a/lib/stat.c b/lib/stat.c index 696f3d6..6e4d788 100644 --- a/lib/stat.c +++ b/lib/stat.c @@ -29,16 +29,6 @@ #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ # define WINDOWS_NATIVE -# if _GL_WINDOWS_64_BIT_ST_SIZE -# undef stat /* avoid warning on mingw64 with _FILE_OFFSET_BITS=64 */ -# define stat _stati64 -# undef REPLACE_FUNC_STAT_FILE -# elif REPLACE_FUNC_STAT_FILE -/* mingw64 has a broken stat() function, based on _stat(), in libmingwex.a. - Bypass it. */ -# define stat _stat -# undef REPLACE_FUNC_STAT_FILE -# endif #endif #if !defined WINDOWS_NATIVE