From f7c5a7a19eb8dc128284911bf1046b0f69a50a16 Mon Sep 17 00:00:00 2001 From: Kenneth Perry Date: Thu, 3 May 2018 17:21:56 -0500 Subject: [PATCH] routing/chainview/neutrino: error if we get a nil cfilter back (#1176) --- routing/chainview/neutrino.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/routing/chainview/neutrino.go b/routing/chainview/neutrino.go index e464f2b19..6b98f598e 100644 --- a/routing/chainview/neutrino.go +++ b/routing/chainview/neutrino.go @@ -241,6 +241,10 @@ func (c *CfFilteredChainView) FilterBlock(blockHash *chainhash.Hash) (*FilteredB return nil, err } + if filter == nil { + return nil, fmt.Errorf("Unable to fetch filter") + } + // Before we can match the filter, we'll need to map each item in our // chain filter to the representation that included in the compact // filters.