]> Savannah Git Hosting - gnulib.git/commitdiff
stat, fstat: Complete removal of old native Windows code.
authorBruno Haible <bruno@clisp.org>
Sat, 13 May 2017 00:36:19 +0000 (02:36 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 13 May 2017 00:36:19 +0000 (02:36 +0200)
* lib/stat.c: Remove old macrology for WINDOWS_NATIVE.
* lib/fstat.c: Likewise.
* lib/stat-w32.c: Likewise.

ChangeLog
lib/fstat.c
lib/stat-w32.c
lib/stat.c

index 17f835dd92414fe51085da35118a5ab376a5a420..f6cee1dc265c11f32c7c3a5e7c5533ea1d8bd372 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2017-05-13  Bruno Haible  <bruno@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.
+
 2017-05-13  Bruno Haible  <bruno@clisp.org>
 
        stat: Complete removal of REPLACE_FUNC_STAT_DIR code.
index 605ac7d85ec63a5c122745d497fb8793a5bb12d2..d2e04688f253cef87104192134355e0e99360d6c 100644 (file)
 
 #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
index 4f4a105812ec013d875bcbf6b410ced6f8f98410..4818a57a8c625918cecb155eaef0e766d327af69 100644 (file)
 
 #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,
index 696f3d643a4f06f3d2a7bafa0df1f7febb3f817b..6e4d788ab7348a6a4ba5e93bb356f55eee834e1e 100644 (file)
 
 #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