From 883c9f960cc01385a03d01059067f1f6243b9754 Mon Sep 17 00:00:00 2001 From: Leonid Yuriev Date: Tue, 1 Sep 2020 13:21:02 +0300 Subject: [PATCH] mdbx++: don't use obsolete MDBX_MAPASYNC. Change-Id: I328772a36d14a7593f3b9ee31796fb33d30de7b0 --- src/mdbx.c++ | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mdbx.c++ b/src/mdbx.c++ index 18d6307c..c1613d70 100644 --- a/src/mdbx.c++ +++ b/src/mdbx.c++ @@ -1061,7 +1061,8 @@ __cold MDBX_env_flags_t env_ref::operate_parameters::make_flags( flags |= MDBX_NOMETASYNC; break; case env_ref::durability::lazy_weak_tail: - flags |= (flags & MDBX_WRITEMAP) ? MDBX_MAPASYNC : MDBX_SAFE_NOSYNC; + static_assert(MDBX_MAPASYNC == MDBX_SAFE_NOSYNC, "WTF? Obsolete C API?"); + flags |= MDBX_SAFE_NOSYNC; break; case env_ref::durability::whole_fragile: flags |= MDBX_UTTERLY_NOSYNC;