From 3c9786b5e8dae8a6e8e49a83c55824eb8e4f2cea Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Mon, 9 Nov 2015 20:09:10 +0000 Subject: [PATCH] ITS#8304 fix page_merge Was using the pre-touch dst page pointer instead of the touched page --- libraries/liblmdb/mdb.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libraries/liblmdb/mdb.c b/libraries/liblmdb/mdb.c index 59222cadea..6d9e0a4415 100644 --- a/libraries/liblmdb/mdb.c +++ b/libraries/liblmdb/mdb.c @@ -7854,6 +7854,9 @@ mdb_page_merge(MDB_cursor *csrc, MDB_cursor *cdst) if ((rc = mdb_page_touch(cdst))) return rc; + /* get dst page again now that we've touched it. */ + pdst = cdst->mc_pg[cdst->mc_top]; + /* Move all nodes from src to dst. */ j = nkeys = NUMKEYS(pdst); -- 2.39.5