Removed C90 limitations and NO_LONG_LONG related stuff as even MinGW on Windows 2000... master
authorRobert Pengelly <robertapengelly@hotmail.com>
Wed, 19 Aug 2026 11:37:51 +0000 (12:37 +0100)
committerRobert Pengelly <robertapengelly@hotmail.com>
Wed, 19 Aug 2026 11:37:51 +0000 (12:37 +0100)
Makefile.unix
Makefile.w32
e2cp.c

index b5028c0e0f48d42448652459a034f2927785f4b6..f661f85f602140563cf2c0f5668f4c3c5d2f94aa 100644 (file)
@@ -5,7 +5,7 @@ SRCDIR              ?=  $(CURDIR)
 VPATH               :=  $(SRCDIR)
 
 CC                  :=  gcc
-CFLAGS              :=  -D_FILE_OFFSET_BITS=64 -Wall -Werror -Wextra -std=c90
+CFLAGS              :=  -D_FILE_OFFSET_BITS=64 -Wall -Werror -Wextra
 
 ifeq ($(OS), Windows_NT)
 all: mke2fs.exe e2md.exe e2cp.exe mke2nod.exe
index c6a75f2daa8c9c3d7814fe4fc3078f0aac4b2aa8..3580ebb6262723e6f030871607b1314f30c0b8e3 100644 (file)
@@ -5,7 +5,7 @@ SRCDIR              ?=  $(CURDIR)
 VPATH               :=  $(SRCDIR)
 
 CC                  :=  gcc
-CFLAGS              :=  -D_FILE_OFFSET_BITS=64 -Wall -Werror -Wextra -std=c90
+CFLAGS              :=  -D_FILE_OFFSET_BITS=64 -Wall -Werror -Wextra
 
 all: mke2fs.exe e2md.exe e2cp.exe mke2nod.exe
 
diff --git a/e2cp.c b/e2cp.c
index fe2c09776d0e09a32dc3ca88b4ba8c23b21d7b74..f854c05069f596127b75e3d748c12d6ee32e92c9 100644 (file)
--- a/e2cp.c
+++ b/e2cp.c
@@ -448,11 +448,12 @@ static int walk_path (struct filesystem *fs, char *dirname) {
 # if   defined (__CYGWIN__)
 #  include  <sys/socket.h>
 # endif
+#endif
 
 /** Get a single character from the terminal. */
 static char getch (void) {
 
-#if     defined(_WIN32)
+#if     defined (_WIN32)
 
     KEY_EVENT_RECORD keyevent;
     INPUT_RECORD irec;
@@ -539,8 +540,6 @@ static char getch (void) {
             ioctl (0, FIONREAD, &nbbytes);                  /* 0 is STDIN */
         
         }
-
-#endif
         
         key = (int) getchar ();