chainntnfs: ensure ntfn cancellation loop will exit
This commit fixes a slight bug introduced. We now ensure that the cancel loop always exists if the ChainNotifier has been signaled for a quit.
This commit is contained in:
parent
b6057abe93
commit
399d9c974f
@ -692,6 +692,7 @@ func (b *BtcdNotifier) RegisterSpendNtfn(outpoint *wire.OutPoint,
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
case <-b.quit:
|
case <-b.quit:
|
||||||
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case <-b.quit:
|
case <-b.quit:
|
||||||
@ -788,6 +789,7 @@ func (b *BtcdNotifier) RegisterBlockEpochNtfn() (*chainntnfs.BlockEpochEvent, er
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
case <-b.quit:
|
case <-b.quit:
|
||||||
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case <-b.quit:
|
case <-b.quit:
|
||||||
|
@ -722,6 +722,7 @@ func (n *NeutrinoNotifier) RegisterSpendNtfn(outpoint *wire.OutPoint,
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
case <-n.quit:
|
case <-n.quit:
|
||||||
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case <-n.quit:
|
case <-n.quit:
|
||||||
@ -891,6 +892,7 @@ func (n *NeutrinoNotifier) RegisterBlockEpochNtfn() (*chainntnfs.BlockEpochEvent
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
case <-n.quit:
|
case <-n.quit:
|
||||||
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case <-n.quit:
|
case <-n.quit:
|
||||||
|
Loading…
Reference in New Issue
Block a user