util.h must be the first include to #define _POSIX_C_SOURCE

This commit is contained in:
inikep
2016-04-29 15:18:50 +02:00
parent 55d047aa92
commit 4f832c9f26
5 changed files with 5 additions and 4 deletions
+1
View File
@@ -436,6 +436,7 @@ static void BMK_loadFiles(void* buffer, size_t bufferSize,
U64 fileSize = UTIL_getFileSize(fileNamesTable[n]); U64 fileSize = UTIL_getFileSize(fileNamesTable[n]);
if (UTIL_isDirectory(fileNamesTable[n])) { if (UTIL_isDirectory(fileNamesTable[n])) {
DISPLAYLEVEL(2, "Ignoring %s directory... \n", fileNamesTable[n]); DISPLAYLEVEL(2, "Ignoring %s directory... \n", fileNamesTable[n]);
fileSizes[n] = 0;
continue; continue;
} }
f = fopen(fileNamesTable[n], "rb"); f = fopen(fileNamesTable[n], "rb");
+1 -1
View File
@@ -43,11 +43,11 @@
/*-************************************* /*-*************************************
* Includes * Includes
***************************************/ ***************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdlib.h> /* malloc, free */ #include <stdlib.h> /* malloc, free */
#include <string.h> /* memset */ #include <string.h> /* memset */
#include <stdio.h> /* fprintf, fopen, ftello64 */ #include <stdio.h> /* fprintf, fopen, ftello64 */
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h" /* read */ #include "mem.h" /* read */
#include "error_private.h" #include "error_private.h"
#include "dibio.h" #include "dibio.h"
+1 -1
View File
@@ -50,6 +50,7 @@
/*-************************************ /*-************************************
* Dependencies * Dependencies
**************************************/ **************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdlib.h> /* malloc */ #include <stdlib.h> /* malloc */
#include <stdio.h> /* fprintf, fopen, ftello64 */ #include <stdio.h> /* fprintf, fopen, ftello64 */
#include <string.h> /* strcmp */ #include <string.h> /* strcmp */
@@ -62,7 +63,6 @@
# include <sys/time.h> /* gettimeofday */ # include <sys/time.h> /* gettimeofday */
#endif #endif
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h" #include "mem.h"
#include "zstd_static.h" #include "zstd_static.h"
#include "datagen.h" #include "datagen.h"