mirror of
https://github.com/isar/libmdbx.git
synced 2024-12-29 09:38:49 +08:00
mdbx-testing: корректировка контроля результата в copy-сценарии.
This commit is contained in:
parent
f5b1e36b9e
commit
12442bd1f4
@ -43,13 +43,16 @@ void testcase_copy::copy_db(const bool with_compaction) {
|
|||||||
txn_begin(ro);
|
txn_begin(ro);
|
||||||
err =
|
err =
|
||||||
mdbx_txn_copy2pathname(txn_guard.get(), copy_pathname.c_str(), flags);
|
mdbx_txn_copy2pathname(txn_guard.get(), copy_pathname.c_str(), flags);
|
||||||
if (unlikely(err != MDBX_SUCCESS && (!throttle || err != MDBX_OUSTED) &&
|
txn_end(err != MDBX_SUCCESS || flipcoin());
|
||||||
(!enable_renew && err != MDBX_MVCC_RETARDED)))
|
if (unlikely(
|
||||||
|
err != MDBX_SUCCESS && !(throttle && err == MDBX_OUSTED) &&
|
||||||
|
!(!enable_renew && err == MDBX_MVCC_RETARDED) &&
|
||||||
|
!(err == MDBX_EINVAL && !ro &&
|
||||||
|
(flags & (MDBX_CP_THROTTLE_MVCC | MDBX_CP_RENEW_TXN)) != 0)))
|
||||||
failure_perror(with_compaction
|
failure_perror(with_compaction
|
||||||
? "mdbx_txn_copy2pathname(MDBX_CP_COMPACT)"
|
? "mdbx_txn_copy2pathname(MDBX_CP_COMPACT)"
|
||||||
: "mdbx_txn_copy2pathname(MDBX_CP_ASIS)",
|
: "mdbx_txn_copy2pathname(MDBX_CP_ASIS)",
|
||||||
err);
|
err);
|
||||||
txn_end(err != MDBX_SUCCESS || flipcoin());
|
|
||||||
} while (err != MDBX_SUCCESS);
|
} while (err != MDBX_SUCCESS);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user