aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2020-11-15 18:33:47 +0100
committerMarcoFalke <falke.marco@gmail.com>2020-11-15 18:33:59 +0100
commit0ede354367c478cbbed0ec40a9d3cf1efe74cf33 (patch)
treee7e6379dcbd233f7e3590d216a249ad2d20b56fc
parentfb7726e56d0f0617076c89cbc279547cc9d07341 (diff)
parent049feabf289ace817a3da62fe84942d0200b8f0b (diff)
downloadbitcoin-0ede354367c478cbbed0ec40a9d3cf1efe74cf33.tar.xz
Merge #20386: Silence false positive GCC warning in wallet/rpcwallet.cpp
049feabf289ace817a3da62fe84942d0200b8f0b Add missing optional.h include (Kristaps Kaupe) 29c66ace5c777b56cd9e19756a1ab0801d15a5ae Silence false positive GCC warning (Kristaps Kaupe) Pull request description: Resolves #20381. ACKs for top commit: jnewbery: utACK 049feabf289ace817a3da62fe84942d0200b8f0b practicalswift: ACK 049feabf289ace817a3da62fe84942d0200b8f0b: diagnostics signal to noise is increased by getting rid of false positives hebasto: ACK 049feabf289ace817a3da62fe84942d0200b8f0b, I have reviewed the code and it looks OK, I agree it can be merged. Tree-SHA512: 05d84f51521c3b843ed6bf284a83a91db015ad0cd4fcf8b602275812575c1f6b4899286a89d360fbd3caef184abdfb9d834e119842d8740919892f05a0f9e1f8
-rw-r--r--src/wallet/rpcwallet.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp
index ebcab1227d..0fbb212732 100644
--- a/src/wallet/rpcwallet.cpp
+++ b/src/wallet/rpcwallet.cpp
@@ -8,6 +8,7 @@
#include <interfaces/chain.h>
#include <key_io.h>
#include <node/context.h>
+#include <optional.h>
#include <outputtype.h>
#include <policy/feerate.h>
#include <policy/fees.h>
@@ -3593,7 +3594,7 @@ static RPCHelpMan rescanblockchain()
}
int start_height = 0;
- Optional<int> stop_height;
+ Optional<int> stop_height = MakeOptional(false, int());
uint256 start_block;
{
LOCK(pwallet->cs_wallet);