chainntnfs: fix recursive loop, add additional logging

This commit is contained in:
Olaoluwa Osuntokun 2016-09-12 19:03:50 -07:00
parent 80b09f7d6f
commit 39044cb2fa
No known key found for this signature in database
GPG Key ID: 9CC5B105D03521A2

@ -157,7 +157,6 @@ func (b *BtcdNotifier) onBlockConnected(hash *wire.ShaHash, height int32, t time
// onBlockDisconnected implements on OnBlockDisconnected callback for btcrpcclient.
func (b *BtcdNotifier) onBlockDisconnected(hash *wire.ShaHash, height int32, t time.Time) {
b.onBlockDisconnected(hash, height, t)
}
// onRedeemingTx implements on OnRedeemingTx callback for btcrpcclient.
@ -248,6 +247,9 @@ out:
SpenderInputIndex: uint32(i),
}
chainntnfs.Log.Infof("Dispatching "+
"spend notification for "+
"outpoint=%v", ntfn.targetOutpoint)
ntfn.spendChan <- spendDetails
delete(b.spendNotifications, prevOut)
}