mdbx: don't keep extra space while update on overflow-pages.

Change-Id: I70f2a87e0e9ec088f692021cfcfcd1b81f287e31
This commit is contained in:
Leonid Yuriev 2018-08-16 11:51:24 +03:00
parent d3e9626a15
commit cb081424ff

View File

@ -7893,7 +7893,8 @@ int mdbx_cursor_put(MDBX_cursor *mc, MDBX_val *key, MDBX_val *data,
ovpages = omp->mp_pages;
/* Is the ov page large enough? */
if (ovpages >= dpages) {
if (ovpages ==
/* LY: add configuragle theshold to keep reserve space */ dpages) {
if (!(omp->mp_flags & P_DIRTY) &&
(level || (env->me_flags & MDBX_WRITEMAP))) {
rc = mdbx_page_unspill(mc->mc_txn, omp, &omp);