]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
allow all operationg systems with _POSIX_C_SOURCE >= 200112L 476/head
authorPrzemyslaw Skibinski <inikep@gmail.com>
Mon, 12 Dec 2016 14:37:43 +0000 (15:37 +0100)
committerPrzemyslaw Skibinski <inikep@gmail.com>
Mon, 12 Dec 2016 14:37:43 +0000 (15:37 +0100)
programs/util.h

index 7552250dd6eb21b76cc0fa347db6fff012f37734..e7c6b0569d1d496814b6f598cc84b23eb625c0a2 100644 (file)
@@ -325,9 +325,10 @@ UTIL_STATIC int UTIL_prepareFileList(const char *dirName, char** bufStart, size_
     return nbFiles;
 }
 
-#elif (defined(__APPLE__) && defined(__MACH__)) || defined(__SVR4) || defined(_AIX) || defined(__hpux) || \
+#elif (defined(_POSIX_C_SOURCE) && (_POSIX_C_SOURCE >= 200112L)) || \
+      (defined(__APPLE__) && defined(__MACH__)) || defined(__SVR4) || defined(_AIX) || defined(__hpux) || \
        defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || \
-     ((defined(__unix__) || defined(__unix) || defined(__midipix__)) && defined(_POSIX_C_SOURCE) && (_POSIX_C_SOURCE >= 200112L)) /* snprintf, opendir */
+      (defined(__linux__) && defined(_POSIX_C_SOURCE)) /* opendir */
 #  define UTIL_HAS_CREATEFILELIST
 #  include <dirent.h>       /* opendir, readdir */