]> Savannah Git Hosting - gnulib.git/commitdiff
ftello: Fix override on mingw.
authorBruno Haible <bruno@clisp.org>
Thu, 14 Nov 2024 04:18:00 +0000 (05:18 +0100)
committerBruno Haible <bruno@clisp.org>
Thu, 14 Nov 2024 04:18:00 +0000 (05:18 +0100)
Reported by Markus Mützel <markus.muetzel@gmx.de> in
<https://lists.gnu.org/archive/html/bug-gnulib/2024-11/msg00108.html>.

* lib/ftello.c: Test whether module 'largefile' is in use, not
whether it had to override 'off_t'.

ChangeLog
lib/ftello.c

index 2cb13075e1723002efd4066fd118b4b97769cef0..671d025e30228079a2d5d57eba4cef67de0926f1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2024-11-14  Bruno Haible  <bruno@clisp.org>
+
+       ftello: Fix override on mingw.
+       Reported by Markus Mützel <markus.muetzel@gmx.de> in
+       <https://lists.gnu.org/archive/html/bug-gnulib/2024-11/msg00108.html>.
+       * lib/ftello.c: Test whether module 'largefile' is in use, not
+       whether it had to override 'off_t'.
+
 2024-11-14  Bruno Haible  <bruno@clisp.org>
 
        fseeko: Fix potentially wrong override.
index 88247bca8e3aa30c758806cbbc79f55448d8161b..37fe93a34e00826383aabd4cd60f7aabde142581 100644 (file)
@@ -34,7 +34,7 @@ ftello (FILE *fp)
 # undef ftell
 # define ftello ftell
 #endif
-#if _GL_WINDOWS_64_BIT_OFF_T
+#if (defined _WIN32 && !defined __CYGWIN__) && _FILE_OFFSET_BITS == 64
 # undef ftello
 # if HAVE__FTELLI64 /* msvc, mingw64 */
 #  define ftello _ftelli64