From 87d91316cde1a670324f41c122999b9eeddaf31a Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Thu, 14 Jun 2018 22:01:50 -0700 Subject: [PATCH] chain: update interface to map outpoints to their addresses In this commit, we update the Rescan call in the interface to map the outpoint to the address that the outpoint holds. We do this as BIP 158 has recently been updated to match on the prev output script rather than the outpoint itself. Additionally, in the near future, btcd (then bitcoind), will switch over to using the BIP 158 filters internally, which will also match on the output scripts. --- chain/interface.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chain/interface.go b/chain/interface.go index 8f26a5c..1f201d3 100644 --- a/chain/interface.go +++ b/chain/interface.go @@ -34,7 +34,7 @@ type Interface interface { FilterBlocks(*FilterBlocksRequest) (*FilterBlocksResponse, error) BlockStamp() (*waddrmgr.BlockStamp, error) SendRawTransaction(*wire.MsgTx, bool) (*chainhash.Hash, error) - Rescan(*chainhash.Hash, []btcutil.Address, []*wire.OutPoint) error + Rescan(*chainhash.Hash, []btcutil.Address, map[wire.OutPoint]btcutil.Address) error NotifyReceived([]btcutil.Address) error NotifyBlocks() error Notifications() <-chan interface{}