Skip to content

Commit 1d94c40

Browse files
kbleesgitster
authored andcommitted
Win32 dirent: remove unused dirent.d_ino member
There are no proper inodes on Windows, so remove dirent.d_ino and #define NO_D_INO_IN_DIRENT in the Makefile (this skips e.g. an ineffective qsort in fsck.c). Signed-off-by: Karsten Blees <[email protected]> Signed-off-by: Erik Faye-Lund <[email protected]> Signed-off-by: Stepan Kasal <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent bce14aa commit 1d94c40

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

compat/win32/dirent.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ typedef struct DIR DIR;
99
#define DT_LNK 3
1010

1111
struct dirent {
12-
long d_ino; /* Always zero. */
1312
char d_name[FILENAME_MAX]; /* File name. */
1413
union {
1514
unsigned short d_reclen; /* Always zero. */

config.mak.uname

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,7 @@ ifeq ($(uname_S),Windows)
349349
NO_POSIX_GOODIES = UnfortunatelyYes
350350
NATIVE_CRLF = YesPlease
351351
DEFAULT_HELP_FORMAT = html
352+
NO_D_INO_IN_DIRENT = YesPlease
352353

353354
CC = compat/vcbuild/scripts/clink.pl
354355
AR = compat/vcbuild/scripts/lib.pl
@@ -497,6 +498,7 @@ ifneq (,$(findstring MINGW,$(uname_S)))
497498
NO_INET_NTOP = YesPlease
498499
NO_POSIX_GOODIES = UnfortunatelyYes
499500
DEFAULT_HELP_FORMAT = html
501+
NO_D_INO_IN_DIRENT = YesPlease
500502
COMPAT_CFLAGS += -D__USE_MINGW_ACCESS -D_USE_32BIT_TIME_T -DNOGDI -Icompat -Icompat/win32
501503
COMPAT_CFLAGS += -DSTRIP_EXTENSION=\".exe\"
502504
COMPAT_OBJS += compat/mingw.o compat/winansi.o \

0 commit comments

Comments
 (0)