Commit b4ddec0b authored by Hallvard Furuseth's avatar Hallvard Furuseth Committed by Howard Chu
Browse files

Expose MDB_ENCRYPT flag

parent 6e1f7485
...@@ -5707,8 +5707,9 @@ mdb_env_envflags(MDB_env *env) ...@@ -5707,8 +5707,9 @@ mdb_env_envflags(MDB_env *env)
#define CHANGEABLE (MDB_NOSYNC|MDB_NOMETASYNC|MDB_MAPASYNC|MDB_NOMEMINIT) #define CHANGEABLE (MDB_NOSYNC|MDB_NOMETASYNC|MDB_MAPASYNC|MDB_NOMEMINIT)
#define CHANGELESS (MDB_FIXEDMAP|MDB_NOSUBDIR|MDB_RDONLY| \ #define CHANGELESS (MDB_FIXEDMAP|MDB_NOSUBDIR|MDB_RDONLY| \
MDB_WRITEMAP|MDB_NOTLS|MDB_NOLOCK|MDB_NORDAHEAD|MDB_REMAP_CHUNKS) MDB_WRITEMAP|MDB_NOTLS|MDB_NOLOCK|MDB_NORDAHEAD|MDB_REMAP_CHUNKS)
#define EXPOSED (CHANGEABLE|CHANGELESS | MDB_ENCRYPT)
#if VALID_FLAGS & PERSISTENT_FLAGS & (CHANGEABLE|CHANGELESS) #if VALID_FLAGS & PERSISTENT_FLAGS & EXPOSED
# error "Persistent DB flags & env flags overlap, but both go in mm_flags" # error "Persistent DB flags & env flags overlap, but both go in mm_flags"
#endif #endif
...@@ -10909,7 +10910,7 @@ mdb_env_get_flags(MDB_env *env, unsigned int *arg) ...@@ -10909,7 +10910,7 @@ mdb_env_get_flags(MDB_env *env, unsigned int *arg)
if (!env || !arg) if (!env || !arg)
return EINVAL; return EINVAL;
*arg = env->me_flags & (CHANGEABLE|CHANGELESS); *arg = env->me_flags & EXPOSED;
return MDB_SUCCESS; return MDB_SUCCESS;
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment