mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-25 14:28:53 +02:00
Avoid unintentional unsigned integer wraparounds in tests
This commit is contained in:
@@ -82,7 +82,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
|
||||
wtx.mapValue["comment"] = "y";
|
||||
{
|
||||
CMutableTransaction tx(*wtx.tx);
|
||||
--tx.nLockTime; // Just to change the hash :)
|
||||
++tx.nLockTime; // Just to change the hash :)
|
||||
wtx.SetTx(MakeTransactionRef(std::move(tx)));
|
||||
}
|
||||
pwalletMain->AddToWallet(wtx);
|
||||
@@ -92,7 +92,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
|
||||
wtx.mapValue["comment"] = "x";
|
||||
{
|
||||
CMutableTransaction tx(*wtx.tx);
|
||||
--tx.nLockTime; // Just to change the hash :)
|
||||
++tx.nLockTime; // Just to change the hash :)
|
||||
wtx.SetTx(MakeTransactionRef(std::move(tx)));
|
||||
}
|
||||
pwalletMain->AddToWallet(wtx);
|
||||
|
||||
Reference in New Issue
Block a user