Skip to content

Commit 5217a80

Browse files
committed
loopout: close sweepbatcher quitChan
This is needed because sweepbatcher can use this channel in multiple select statements to unblock itself if the caller cancels.
1 parent 6d82f64 commit 5217a80

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

loopout.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1148,7 +1148,7 @@ func (s *loopOutSwap) waitForHtlcSpendConfirmedV2(globalCtx context.Context,
11481148
quitChan := make(chan bool, 1)
11491149

11501150
defer func() {
1151-
quitChan <- true
1151+
close(quitChan)
11521152
}()
11531153

11541154
notifier := sweepbatcher.SpendNotifier{

0 commit comments

Comments
 (0)