diff --git a/src/test/fuzz/script_flags.cpp b/src/test/fuzz/script_flags.cpp index 88c9b8f0c5667c..7a2f6af522a4d8 100644 --- a/src/test/fuzz/script_flags.cpp +++ b/src/test/fuzz/script_flags.cpp @@ -38,6 +38,10 @@ void test_one_input(const std::vector& buffer) for (unsigned i = 0; i < tx.vin.size(); ++i) { CTxOut prevout; ds >> prevout; + if (!MoneyRange(prevout.nValue)) { + // prevouts should be consensus-valid + prevout.nValue = 1; + } spent_outputs.push_back(prevout); } PrecomputedTransactionData txdata;