Skip to content

Commit e507a51

Browse files
committed
fix: avoid mandatory-script-verify-flag-failed crash in bench test
Aberrant behaviour was first introduced in 5d10b41 (dash#6152), changes meant for SegWit made it in, reverting them fixes the problem.
1 parent a86109a commit e507a51

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bench/block_assemble.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ static void AssembleBlock(benchmark::Bench& bench)
3232
std::array<CTransactionRef, NUM_BLOCKS - COINBASE_MATURITY + 1> txs;
3333
for (size_t b{0}; b < NUM_BLOCKS; ++b) {
3434
CMutableTransaction tx;
35-
tx.vin.push_back(MineBlock(test_setup->m_node, P2SH_OP_TRUE));
35+
tx.vin.push_back(MineBlock(test_setup->m_node, SCRIPT_PUB));
3636
tx.vin.back().scriptSig = scriptSig;
3737
tx.vout.emplace_back(1337, SCRIPT_PUB);
3838
if (NUM_BLOCKS - b >= COINBASE_MATURITY)
@@ -48,7 +48,7 @@ static void AssembleBlock(benchmark::Bench& bench)
4848
}
4949

5050
bench.minEpochIterations(700).run([&] {
51-
PrepareBlock(test_setup->m_node, P2SH_OP_TRUE);
51+
PrepareBlock(test_setup->m_node, SCRIPT_PUB);
5252
});
5353
}
5454

0 commit comments

Comments
 (0)