fix macro HAVE_O_CLOEXEC when O_CLOEXEC not found

This commit is contained in:
emptyx.wong 2022-06-09 14:50:01 +08:00
parent d019e3605f
commit 923abf5d2d

View File

@ -50,7 +50,7 @@ constexpr const int kDefaultMmapLimit = (sizeof(void*) >= 8) ? 1000 : 0;
int g_mmap_limit = kDefaultMmapLimit; int g_mmap_limit = kDefaultMmapLimit;
// Common flags defined for all posix open operations // Common flags defined for all posix open operations
#if defined(HAVE_O_CLOEXEC) #if HAVE_O_CLOEXEC
constexpr const int kOpenBaseFlags = O_CLOEXEC; constexpr const int kOpenBaseFlags = O_CLOEXEC;
#else #else
constexpr const int kOpenBaseFlags = 0; constexpr const int kOpenBaseFlags = 0;