dfd9f6d1ca
This commit fixes to distinct bugs in the way we previously dipatched notifications for transactions which needed a historical dispatch. Previously we would compare transactions when scanning the block using the `tx.Hash` field. This was incorrect has the `Hash` field is actually the wtxid, not the txid which should be the item being compared. We fix this within the second bug fix by actually using the txid to find the proper transaction. The second fix has to due with a slight race condition which led to an off-by-one error when dispatching the historical confirmation. If while we were dispatching the confirmation, a new block was found, then we could calculate the wrong block height (off by one) as we were using the ‘currentHeight’ instead the height of the block which included the transaction. |
||
---|---|---|
.. | ||
btcd.go | ||
confheap.go | ||
driver.go |