Commit fbabe86
committed
Merge bitcoin/bitcoin#34870: wallet: feebumper, fix crash when combined bump fee is unavailable
6072a2a wallet: feebumper, fix crash when combined bump fee is unavailable (furszy)
Pull request description:
When a large cluster of unconfirmed transactions exceeds the limit,
`calculateCombinedBumpFee()` returns `std::nullopt`.
Previously, we continued executing and the optional value was
accessed unconditionally, leading to a `std::bad_optional_access`
exception (https://en.cppreference.com/w/cpp/utility/optional/value.html).
Fix this by returning early when the bumped fee is null.
Note:
This is a crash for the GUI, and an uncaught exception for the RPC
`bumpfee` and `psbtbumpfee`.
ACKs for top commit:
achow101:
ACK 6072a2a
luke-jr:
utACK 6072a2a
rkrux:
crACK 6072a2a based on returning before accessing the null optional.
Tree-SHA512: f863ace1426b2e743e2281e5c624b523de7317c1f305f88f369e77d60005460e4af58b424bc784304fd1ac30a3bfa575137537ec334fa6e449c827daeb262a991 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
83 | | - | |
| 83 | + | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
86 | 87 | | |
87 | 88 | | |
88 | 89 | | |
| |||
0 commit comments