Bootstrap unspents with rescan request's outpoints.
This commit is contained in:
parent
de31674a8d
commit
715fd22de9
1 changed files with 4 additions and 1 deletions
|
@ -1597,7 +1597,7 @@ func handleRescan(wsc *wsClient, icmd btcjson.Cmd) (interface{}, *btcjson.Error)
|
|||
var ripemd160Hash [ripemd160.Size]byte
|
||||
var compressedPubkey [33]byte
|
||||
var uncompressedPubkey [65]byte
|
||||
for addrStr := range cmd.Addresses {
|
||||
for _, addrStr := range cmd.Addresses {
|
||||
addr, err := btcutil.DecodeAddress(addrStr, activeNetParams.btcnet)
|
||||
if err != nil {
|
||||
jsonErr := btcjson.Error{
|
||||
|
@ -1641,6 +1641,9 @@ func handleRescan(wsc *wsClient, icmd btcjson.Cmd) (interface{}, *btcjson.Error)
|
|||
lookups.fallbacks[addrStr] = struct{}{}
|
||||
}
|
||||
}
|
||||
for _, outpoint := range cmd.OutPoints {
|
||||
lookups.unspent[*outpoint] = struct{}{}
|
||||
}
|
||||
|
||||
minBlock := int64(cmd.BeginBlock)
|
||||
maxBlock := int64(cmd.EndBlock)
|
||||
|
|
Loading…
Reference in a new issue