mdbx: возможность вызова osal_lck_destroy() в дочернем процессе после fork().

This commit is contained in:
Леонид Юрьев (Leonid Yuriev)
2023-11-12 00:03:43 +03:00
parent 7ad54f54b4
commit a3e2300f58
4 changed files with 46 additions and 35 deletions

View File

@@ -682,7 +682,9 @@ MDBX_INTERNAL_FUNC int osal_lck_init(MDBX_env *env,
}
MDBX_INTERNAL_FUNC int osal_lck_destroy(MDBX_env *env,
MDBX_env *inprocess_neighbor) {
MDBX_env *inprocess_neighbor,
const uint32_t current_pid) {
(void)current_pid;
/* LY: should unmap before releasing the locks to avoid race condition and
* STATUS_USER_MAPPED_FILE/ERROR_USER_MAPPED_FILE */
if (env->me_map)