Skip to content

Commit 1733c02

Browse files
committed
Drop additional loop_exit_check
We previously introduced an additional `loop_exit_check` in background processor. Since all reviewers seemed to be skeptical about its usefulness, we drop it again here.
1 parent 8a36be4 commit 1733c02

File tree

1 file changed

+1
-8
lines changed
  • lightning-background-processor/src

1 file changed

+1
-8
lines changed

lightning-background-processor/src/lib.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -387,20 +387,13 @@ macro_rules! define_run_body {
387387
// persistence.
388388
$peer_manager.as_ref().process_events();
389389

390-
// Exit the loop if the background processor was requested to stop.
391-
if $loop_exit_check {
392-
log_trace!($logger, "Terminating background processor.");
393-
break;
394-
}
395-
396390
if $timer_elapsed(&mut last_forwards_processing_call, cur_batch_delay) {
397391
$channel_manager.get_cm().process_pending_htlc_forwards();
398392
cur_batch_delay = $batch_delay.next();
399393
last_forwards_processing_call = $get_timer(cur_batch_delay);
400394
}
401395

402-
// Checke whether to exit the loop again, as some time might have passed since we
403-
// checked above.
396+
// Exit the loop if the background processor was requested to stop.
404397
if $loop_exit_check {
405398
log_trace!($logger, "Terminating background processor.");
406399
break;

0 commit comments

Comments
 (0)