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

This commit is contained in:
inikep 2016-04-29 15:19:40 +02:00
parent 55d047aa92
commit bab4317961
5 changed files with 5 additions and 4 deletions

View File

@ -436,6 +436,7 @@ static void BMK_loadFiles(void* buffer, size_t bufferSize,
U64 fileSize = UTIL_getFileSize(fileNamesTable[n]);
if (UTIL_isDirectory(fileNamesTable[n])) {
DISPLAYLEVEL(2, "Ignoring %s directory... \n", fileNamesTable[n]);
fileSizes[n] = 0;
continue;
}
f = fopen(fileNamesTable[n], "rb");

View File

@ -43,11 +43,11 @@
/*-*************************************
* Includes
***************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdlib.h> /* malloc, free */
#include <string.h> /* memset */
#include <stdio.h> /* fprintf, fopen, ftello64 */
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h" /* read */
#include "error_private.h"
#include "dibio.h"

View File

@ -55,13 +55,13 @@
/*-*************************************
* Includes
***************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdio.h> /* fprintf, fopen, fread, _fileno, stdin, stdout */
#include <stdlib.h> /* malloc, free */
#include <string.h> /* strcmp, strlen */
#include <time.h> /* clock */
#include <errno.h> /* errno */
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h"
#include "fileio.h"
#include "zstd_static.h" /* ZSTD_magicNumber, ZSTD_frameHeaderSize_max */

View File

@ -41,12 +41,12 @@
/*_************************************
* Includes
**************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdlib.h> /* malloc */
#include <stdio.h> /* fprintf, fopen, ftello64 */
#include <string.h> /* strcmp */
#include <time.h> /* clock_t, clock, CLOCKS_PER_SEC */
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h"
#include "zstd_static.h"
#include "fse_static.h"

View File

@ -50,6 +50,7 @@
/*-************************************
* Dependencies
**************************************/
#include "util.h" /* UTIL_GetFileSize */
#include <stdlib.h> /* malloc */
#include <stdio.h> /* fprintf, fopen, ftello64 */
#include <string.h> /* strcmp */
@ -62,7 +63,6 @@
# include <sys/time.h> /* gettimeofday */
#endif
#include "util.h" /* UTIL_GetFileSize */
#include "mem.h"
#include "zstd_static.h"
#include "datagen.h"