mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-20 15:19:07 +01:00
Refactor CFeeRate to use FeeFrac internally
Co-authored-by: Abubakar Sadiq Ismail <48946461+ismaelsadeeq@users.noreply.github.com>
This commit is contained in:
@@ -223,7 +223,7 @@ FUZZ_TARGET(feefrac_mul_div)
|
||||
if (mul64 < std::numeric_limits<int64_t>::max() / 1000 &&
|
||||
mul64 > std::numeric_limits<int64_t>::min() / 1000 &&
|
||||
quot_abs < arith_uint256{std::numeric_limits<int64_t>::max() / 1000}) {
|
||||
CFeeRate feerate(mul64, (uint32_t)div);
|
||||
CFeeRate feerate(mul64, div);
|
||||
CAmount feerate_fee{feerate.GetFee(mul32)};
|
||||
auto allowed_gap = static_cast<int64_t>(mul32 / 1000 + 3 + round_down);
|
||||
assert(feerate_fee - res_fee >= -allowed_gap);
|
||||
|
||||
Reference in New Issue
Block a user