Commit 8230b1b6 authored by Leonid Yuriev's avatar Leonid Yuriev Committed by Hallvard Furuseth
Browse files

ITS#7970 LMDB: Critical Heisenbug

Inconsistent reading & SIGSEGV due to the race condition.
parent 1e5d7983
......@@ -2539,7 +2539,10 @@ mdb_txn_renew0(MDB_txn *txn)
return rc;
}
}
txn->mt_txnid = r->mr_txnid = ti->mti_txnid;
do /* LY: Retry on a race, ITS#7970. */
r->mr_txnid = ti->mti_txnid;
while(r->mr_txnid != ti->mti_txnid);
txn->mt_txnid = r->mr_txnid;
txn->mt_u.reader = r;
meta = env->me_metas[txn->mt_txnid & 1];
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment