diff --git a/src/osal.c b/src/osal.c index b08ec899..72b19cfd 100644 --- a/src/osal.c +++ b/src/osal.c @@ -1451,10 +1451,9 @@ MDBX_INTERNAL_FUNC int mdbx_mresize(int flags, mdbx_mmap_t *map, size_t size, LARGE_INTEGER SectionSize; int err, rc = MDBX_SUCCESS; - if (!(flags & MDBX_RDONLY) && limit == map->limit && size > map->current) { + if (!(flags & MDBX_RDONLY) && limit == map->limit && size > map->current && + /* workaround for Wine */ mdbx_NtExtendSection) { /* growth rw-section */ - if (!mdbx_NtExtendSection) - return MDBX_UNABLE_EXTEND_MAPSIZE /* workaround for Wine */; SectionSize.QuadPart = size; status = mdbx_NtExtendSection(map->section, &SectionSize); if (!NT_SUCCESS(status))