lnwallet/channel: use remote dustlimit when generating HTLC sigs
This commit fixes an issue which would arise in some cases when the local and remote dust limits would differ, resulting in lnd not producing the expected number of HTLC signatures. This was a result of checking dust against the local instead of the remote dust limit. A test exercising the scenario is added.
This commit is contained in:
2 files changed
+48
-1
No files matched your search
+1
-1
@@ -2540,7 +2540,7 @@ func genRemoteHtlcSigJobs(keyRing *CommitmentKeyRing,
|
||||
remoteCommitView *commitment) ([]signJob, chan struct{}, error) {
|
||||
|
||||
txHash := remoteCommitView.txn.TxHash()
|
||||
dustLimit := localChanCfg.DustLimit
|
||||
dustLimit := remoteChanCfg.DustLimit
|
||||
feePerKw := remoteCommitView.feePerKw
|
||||
|
||||
// With the keys generated, we'll make a slice with enough capacity to
|
||||
|
||||
Reference in new issue
Block a user