summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-01-19 21:22:56 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-01-19 21:22:56 (GMT)
commit11fcad9b1df2c2cf7d5ada8feb565c97b9777fef (patch)
treea2b88d5c4f0c32a4d74c057bad4b99f513585acf /generic
parent868168e18953894ec72ea898ff4d2f518283184e (diff)
downloadtcl-11fcad9b1df2c2cf7d5ada8feb565c97b9777fef.zip
tcl-11fcad9b1df2c2cf7d5ada8feb565c97b9777fef.tar.gz
tcl-11fcad9b1df2c2cf7d5ada8feb565c97b9777fef.tar.bz2
[Bug-3474726] minGW Tcl_StatBuf not defined correctly in tcl.h
Diffstat (limited to 'generic')
-rw-r--r--generic/tcl.h2
-rw-r--r--generic/tclFCmd.c5
-rw-r--r--generic/tclTest.c5
3 files changed, 11 insertions, 1 deletions
diff --git a/generic/tcl.h b/generic/tcl.h
index ec64cac..b9355da 100644
--- a/generic/tcl.h
+++ b/generic/tcl.h
@@ -381,7 +381,7 @@ typedef struct stati64 Tcl_StatBuf;
# else /* __BORLANDC__ */
# if defined(_WIN64)
typedef struct __stat64 Tcl_StatBuf;
-# elif (defined(_MSC_VER) && (_MSC_VER < 1400))
+# elif (defined(_MSC_VER) && (_MSC_VER < 1400)) || defined(_USE_32BIT_TIME_T)
typedef struct _stati64 Tcl_StatBuf;
# else
typedef struct _stat32i64 Tcl_StatBuf;
diff --git a/generic/tclFCmd.c b/generic/tclFCmd.c
index 1f73cf3..6113cf7 100644
--- a/generic/tclFCmd.c
+++ b/generic/tclFCmd.c
@@ -10,6 +10,11 @@
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*/
+#ifndef _WIN64
+/* See [Bug 2935503]: file mtime sets wrong time */
+# define _USE_32BIT_TIME_T
+#endif
+
#include <sys/stat.h>
#include "tclInt.h"
#include "tclPort.h"
diff --git a/generic/tclTest.c b/generic/tclTest.c
index e870236..194f110 100644
--- a/generic/tclTest.c
+++ b/generic/tclTest.c
@@ -15,6 +15,11 @@
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*/
+#ifndef _WIN64
+/* See [Bug 2935503]: file mtime sets wrong time */
+# define _USE_32BIT_TIME_T
+#endif
+
#define TCL_TEST
#include <sys/stat.h>
#include "tclInt.h"