From e740df6e500874a286e52b3d2950a6858e79044d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9B=D0=B5=D0=BE=D0=BD=D0=B8=D0=B4=20=D0=AE=D1=80=D1=8C?= =?UTF-8?q?=D0=B5=D0=B2=20=28Leonid=20Yuriev=29?= Date: Wed, 2 Feb 2022 14:04:56 +0300 Subject: [PATCH] mdbx: fix description of `mdbx_env_set_geometry()`. Oops, I just noticed that there are a strange typos in the description. It looks like a search&replace or cut&paste mistake. Related to https://github.com/LWJGL/lwjgl3/issues/724. --- mdbx.h | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/mdbx.h b/mdbx.h index c2a4bb40..3923f6e4 100644 --- a/mdbx.h +++ b/mdbx.h @@ -2690,17 +2690,18 @@ LIBMDBX_API int mdbx_env_get_fd(const MDBX_env *env, mdbx_filehandle_t *fd); * it is reasonable to know some details in order to make optimal decisions * when choosing parameters. * - * Both \ref mdbx_env_info_ex() and legacy \ref mdbx_env_info() are inapplicable - * to read-only opened environment. + * Both \ref mdbx_env_set_geometry() and legacy \ref mdbx_env_set_mapsize() are + * inapplicable to read-only opened environment. * - * Both \ref mdbx_env_info_ex() and legacy \ref mdbx_env_info() could be called - * either before or after \ref mdbx_env_open(), either within the write - * transaction running by current thread or not: + * Both \ref mdbx_env_set_geometry() and legacy \ref mdbx_env_set_mapsize() + * could be called either before or after \ref mdbx_env_open(), either within + * the write transaction running by current thread or not: * - * - In case \ref mdbx_env_info_ex() or legacy \ref mdbx_env_info() was called - * BEFORE \ref mdbx_env_open(), i.e. for closed environment, then the - * specified parameters will be used for new database creation, or will be - * applied during opening if database exists and no other process using it. + * - In case \ref mdbx_env_set_geometry() or legacy \ref mdbx_env_set_mapsize() + * was called BEFORE \ref mdbx_env_open(), i.e. for closed environment, then + * the specified parameters will be used for new database creation, + * or will be applied during opening if database exists and no other process + * using it. * * If the database is already exist, opened with \ref MDBX_EXCLUSIVE or not * used by any other process, and parameters specified by @@ -2713,20 +2714,20 @@ LIBMDBX_API int mdbx_env_get_fd(const MDBX_env *env, mdbx_filehandle_t *fd); * silently discarded (open the database with \ref MDBX_EXCLUSIVE flag * to avoid this). * - * - In case \ref mdbx_env_info_ex() or legacy \ref mdbx_env_info() was called - * after \ref mdbx_env_open() WITHIN the write transaction running by current - * thread, then specified parameters will be applied as a part of write - * transaction, i.e. will not be visible to any others processes until the - * current write transaction has been committed by the current process. + * - In case \ref mdbx_env_set_geometry() or legacy \ref mdbx_env_set_mapsize() + * was called after \ref mdbx_env_open() WITHIN the write transaction running + * by current thread, then specified parameters will be applied as a part of + * write transaction, i.e. will not be visible to any others processes until + * the current write transaction has been committed by the current process. * However, if transaction will be aborted, then the database file will be * reverted to the previous size not immediately, but when a next transaction * will be committed or when the database will be opened next time. * - * - In case \ref mdbx_env_info_ex() or legacy \ref mdbx_env_info() was called - * after \ref mdbx_env_open() but OUTSIDE a write transaction, then MDBX will - * execute internal pseudo-transaction to apply new parameters (but only if - * anything has been changed), and changes be visible to any others processes - * immediately after succesful completion of function. + * - In case \ref mdbx_env_set_geometry() or legacy \ref mdbx_env_set_mapsize() + * was called after \ref mdbx_env_open() but OUTSIDE a write transaction, + * then MDBX will execute internal pseudo-transaction to apply new parameters + * (but only if anything has been changed), and changes be visible to any + * others processes immediately after succesful completion of function. * * Essentially a concept of "automatic size management" is simple and useful: * - There are the lower and upper bound of the database file size;