mirror of
https://github.com/isar/libmdbx.git
synced 2025-11-07 07:18:56 +08:00
mdbx: minor refine and rename mdbx_sync_locked().
Change-Id: Iab650b091006e5646d9d22316d19aa58a517684b
This commit is contained in:
@@ -653,8 +653,8 @@ int mdbx_msync(void *addr, size_t length, int async) {
|
||||
return FlushViewOfFile(addr, length) ? MDBX_SUCCESS
|
||||
: mdbx_get_errno_checked();
|
||||
#else
|
||||
return (msync(addr, length, async ? MS_ASYNC : MS_SYNC) == 0) ? MDBX_SUCCESS
|
||||
: errno;
|
||||
const int mode = async ? MS_ASYNC : MS_SYNC;
|
||||
return (msync(addr, length, mode) == 0) ? MDBX_SUCCESS : errno;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user