]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Fix compiler warnings on MinGW with gcc-4.4.0
authorCharles Wilson <cwilso11@gmail.com>
Thu, 10 Sep 2009 18:17:34 +0000 (14:17 -0400)
committerCharles Wilson <cwilso11@gmail.com>
Thu, 10 Sep 2009 18:17:34 +0000 (14:17 -0400)
* tar/test/main.c (assertion_file_time): Silence 'var may
be used uninitialized' warning.
* cpio/test/main.c (assertion_file_time): Silence 'var may
be used uninitialized' warning.
* libarchive/test/main.c: Don't re-#define chdir.
(assertion_file_time): Silence 'var may be used uninitialized' warning.

SVN-Revision: 1450

cpio/test/main.c
libarchive/test/main.c
tar/test/main.c

index fc957cb79ad10ac3e6ca62d48c059329c2da85a8..e8371b05a08b1ee49aac8b0b255c37cb0f333c61 100644 (file)
@@ -838,6 +838,8 @@ assertion_file_time(const char *file, int line,
        FILETIME ftime, fbirthtime, fatime, fmtime;
        ULARGE_INTEGER wintm;
        HANDLE h;
+       ftime.dwLowDateTime = 0;
+       ftime.dwHighDateTime = 0;
 
        assertion_count(file, line);
        h = CreateFile(pathname, FILE_READ_ATTRIBUTES, 0, NULL,
index 2248b375b50118f27b9aab1e7b675aa268153fb9..296e3f56f4920d772f73e767c155a2f90986bfd2 100644 (file)
@@ -837,6 +837,8 @@ assertion_file_time(const char *file, int line,
        FILETIME ftime, fbirthtime, fatime, fmtime;
        ULARGE_INTEGER wintm;
        HANDLE h;
+       ftime.dwLowDateTime = 0;
+       ftime.dwHighDateTime = 0;
 
        assertion_count(file, line);
        h = CreateFile(pathname, FILE_READ_ATTRIBUTES, 0, NULL,
index 88d14a5f1904bcb91606b02a6282c0e269653c1d..b955b33d6e743e106f48a553adabba94600b1ad9 100644 (file)
@@ -80,7 +80,6 @@ __FBSDID("$FreeBSD: src/usr.bin/tar/test/main.c,v 1.6 2008/11/05 06:40:53 kientz
 #define S_ISREG(m)  ((m) & _S_IFREG)
 #endif
 #define access _access
-#define chdir _chdir
 #ifndef fileno
 #define fileno _fileno
 #endif
@@ -838,6 +837,8 @@ assertion_file_time(const char *file, int line,
        FILETIME ftime, fbirthtime, fatime, fmtime;
        ULARGE_INTEGER wintm;
        HANDLE h;
+       ftime.dwLowDateTime = 0;
+       ftime.dwHighDateTime = 0;
 
        assertion_count(file, line);
        h = CreateFile(pathname, FILE_READ_ATTRIBUTES, 0, NULL,