diff options
author | Eric Wong <e@80x24.org> | 2021-09-22 02:24:34 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-09-22 05:21:22 +0000 |
commit | cafbd77b3c82167d7dd6958c45373a0e92a0e2c5 (patch) | |
tree | 4e97001ef3d330cc6ebb62ed61db67205dc866e1 /lib/PublicInbox/LEI.pm | |
parent | 5c86be0c56d7f250a91c061c00243546d81146ae (diff) | |
download | public-inbox-cafbd77b3c82167d7dd6958c45373a0e92a0e2c5.tar.gz |
We shouldn't dispatch all outputs right away since they can be expensive CPU-wise. Instead, rely on DESTROY to trigger further redispatches. This also fixes a circular reference bug for the single-output case that could lead to a leftover script/lei after MUA exit. I'm not sure how --jobs/-j should work when the actual xsearch and lei2mail has it's own parallelism ("--jobs=$X,$M"), but it's better than having thousands of subtasks running. Fixes: b34a267efff7b831 ("lei up: fix --mua with single output")
Diffstat (limited to 'lib/PublicInbox/LEI.pm')
-rw-r--r-- | lib/PublicInbox/LEI.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/LEI.pm b/lib/PublicInbox/LEI.pm index a1cab55a..1305dfb8 100644 --- a/lib/PublicInbox/LEI.pm +++ b/lib/PublicInbox/LEI.pm @@ -1384,7 +1384,7 @@ sub fchdir { sub wq_eof { # EOF callback for main daemon my ($lei) = @_; my $wq1 = delete $lei->{wq1} // return $lei->fail; # already failed - $wq1->wq_wait_old(\&wq_done_wait, $lei); + $wq1->wq_wait_old($wq1->can('_wq_done_wait') // \&wq_done_wait, $lei); } sub watch_state_ok ($) { |