Skip to content

Commit d5e3123

Browse files
dschogitster
authored andcommitted
Brown paper bag fix for MinGW 64-bit stat
When overriding the identifier "stat" so that "struct stat" will be substituted with "struct _stati64" everywhere, I tried to fix the calls to the _function_ stat(), too, but I forgot to change the earlier attempt "stat64" to "_stati64" there. So, the stat() calls were overridden by calls to _stati64() instead. Unfortunately, there is a function _stati64() so that I missed that calls to stat() were not actually overridden by calls to mingw_lstat(), but t4200-rerere.sh showed the error. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent d0baf91 commit d5e3123

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compat/mingw.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ int mingw_lstat(const char *file_name, struct stat *buf);
170170
int mingw_fstat(int fd, struct stat *buf);
171171
#define fstat mingw_fstat
172172
#define lstat mingw_lstat
173-
#define stat64(x,y) mingw_lstat(x,y)
173+
#define _stati64(x,y) mingw_lstat(x,y)
174174

175175
int mingw_utime(const char *file_name, const struct utimbuf *times);
176176
#define utime mingw_utime

0 commit comments

Comments
 (0)