From 04cad8f7bcd63fac567e49fd72e6df42b3b251a9 Mon Sep 17 00:00:00 2001 From: Thomas Munro Date: Mon, 19 Jul 2021 16:29:17 +1200 Subject: [PATCH] Adjust commit 2dbe8905 for ancient macOS. A couple of open flags used in an assertion didn't exist in macOS 10.4. Per build farm animal prairiedog. Also add O_EXCL while here (there are a few more standard flags but they're not relevant and likely to be missing). --- src/backend/storage/file/fd.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/backend/storage/file/fd.c b/src/backend/storage/file/fd.c index 0792c08ce1..abb054ad7f 100644 --- a/src/backend/storage/file/fd.c +++ b/src/backend/storage/file/fd.c @@ -1065,9 +1065,14 @@ tryAgain: */ StaticAssertStmt((PG_O_DIRECT & (O_APPEND | +#if defined(O_CLOEXEC) O_CLOEXEC | +#endif O_CREAT | +#if defined(O_DSYNC) O_DSYNC | +#endif + O_EXCL | O_RDWR | O_RDONLY | O_SYNC |