mirror of
https://github.com/kaspanet/kaspad.git
synced 2025-03-30 15:08:33 +00:00
Update for recent btcchain orphan notify change.
This commit is contained in:
parent
3525552140
commit
adf7149838
@ -271,8 +271,9 @@ func (b *blockManager) handleNotifyMsg(notification *btcchain.Notification) {
|
||||
switch notification.Type {
|
||||
// An orphan block has been accepted by the block chain.
|
||||
case btcchain.NTOrphanBlock:
|
||||
orphanRoot := notification.Data.(*btcwire.ShaHash)
|
||||
if peer, exists := b.blockPeer[*orphanRoot]; exists {
|
||||
orphanHash := notification.Data.(*btcwire.ShaHash)
|
||||
if peer, exists := b.blockPeer[*orphanHash]; exists {
|
||||
orphanRoot := b.blockChain.GetOrphanRoot(orphanHash)
|
||||
locator, err := b.blockChain.LatestBlockLocator()
|
||||
if err != nil {
|
||||
log.Errorf("[BMGR] Failed to get block locator "+
|
||||
|
Loading…
x
Reference in New Issue
Block a user