mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-22 15:04:44 +01:00
Fix unsigned integer overflow in tapscript validation weight calculation
This commit is contained in:
parent
0ff1391328
commit
fadc54b79b
1 changed files with 2 additions and 2 deletions
|
@ -51,10 +51,10 @@ static const uint32_t LOCKTIME_MAX = 0xFFFFFFFFU;
|
|||
static constexpr unsigned int ANNEX_TAG = 0x50;
|
||||
|
||||
// Validation weight per passing signature (Tapscript only, see BIP 342).
|
||||
static constexpr uint64_t VALIDATION_WEIGHT_PER_SIGOP_PASSED = 50;
|
||||
static constexpr int64_t VALIDATION_WEIGHT_PER_SIGOP_PASSED{50};
|
||||
|
||||
// How much weight budget is added to the witness size (Tapscript only, see BIP 342).
|
||||
static constexpr uint64_t VALIDATION_WEIGHT_OFFSET = 50;
|
||||
static constexpr int64_t VALIDATION_WEIGHT_OFFSET{50};
|
||||
|
||||
template <typename T>
|
||||
std::vector<unsigned char> ToByteVector(const T& in)
|
||||
|
|
Loading…
Add table
Reference in a new issue