mdbx: avoid 32-bit Bionic/Android hang within pthread_mutex_lock().

This commit is contained in:
Леонид Юрьев (Leonid Yuriev)
2022-04-21 15:41:25 +03:00
parent 51d66494fd
commit a2aa6667e1
4 changed files with 41 additions and 5 deletions

View File

@@ -1248,7 +1248,7 @@ static __inline void rthc_lock(void) {
#if defined(_WIN32) || defined(_WIN64)
EnterCriticalSection(&rthc_critical_section);
#else
mdbx_ensure(nullptr, pthread_mutex_lock(&rthc_mutex) == 0);
mdbx_ensure(nullptr, mdbx_pthread_mutex_lock(&rthc_mutex) == 0);
#endif
}
@@ -1596,7 +1596,7 @@ static __inline void lcklist_lock(void) {
#if defined(_WIN32) || defined(_WIN64)
EnterCriticalSection(&lcklist_critical_section);
#else
mdbx_ensure(nullptr, pthread_mutex_lock(&lcklist_mutex) == 0);
mdbx_ensure(nullptr, mdbx_pthread_mutex_lock(&lcklist_mutex) == 0);
#endif
}