multi: remove ErrDoubleSpend check for PublishTransaction
In this commit, we address a lingering issue within some subsystems that are responsible for broadcasting transactions. Previously, ErrDoubleSpend indicated that a transaction was already included in the mempool/chain. This error was then modified to actually be returned for conflicting transactions, but its callers were not modified accordingly. This would lead to conflicting transactions to be interpreted as valid, when they shouldn't be.
This commit is contained in:
4 files changed
+5
-7
No files matched your search
+1
-1
@@ -894,7 +894,7 @@ func (u *utxoNursery) sweepCribOutput(classHeight uint32, baby *babyOutput) erro
|
||||
// We'll now broadcast the HTLC transaction, then wait for it to be
|
||||
// confirmed before transitioning it to kindergarten.
|
||||
err := u.cfg.PublishTransaction(baby.timeoutTx)
|
||||
if err != nil && err != lnwallet.ErrDoubleSpend {
|
||||
if err != nil {
|
||||
utxnLog.Errorf("Unable to broadcast baby tx: "+
|
||||
"%v, %v", err, spew.Sdump(baby.timeoutTx))
|
||||
return err
|
||||
|
||||
Reference in new issue
Block a user