diff options
author | Eric Wong <e@80x24.org> | 2023-01-17 07:19:10 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2023-01-18 23:26:03 +0000 |
commit | 4a2a95bbc78f99c8c5278cfe29de74bd1483903c (patch) | |
tree | 8652affab199e745cb52da49f526a2d998e755fb /lib/PublicInbox/LeiUp.pm | |
parent | f7f0e7bee09cfc57ecc6845a8cf9e80a0bbd64f5 (diff) | |
download | public-inbox-4a2a95bbc78f99c8c5278cfe29de74bd1483903c.tar.gz |
This avoids awkwardly stuffing an arrayref into callbacks which expect multiple arguments. IPC->awaitpid_init now allows pre-registering callbacks before spawning workers.
Diffstat (limited to 'lib/PublicInbox/LeiUp.pm')
-rw-r--r-- | lib/PublicInbox/LeiUp.pm | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/PublicInbox/LeiUp.pm b/lib/PublicInbox/LeiUp.pm index 49917339..3e92242e 100644 --- a/lib/PublicInbox/LeiUp.pm +++ b/lib/PublicInbox/LeiUp.pm @@ -165,9 +165,8 @@ sub _complete_up { # lei__complete hook map { $match_cb->($_) } PublicInbox::LeiSavedSearch::list($lei); } -sub _wq_done_wait { # dwaitpid callback - my ($arg, $pid) = @_; - my ($wq, $lei) = @$arg; +sub _wq_done_wait { # awaitpid cb (via awaitpid_init) + my ($pid, $wq, $lei) = @_; $lei->child_error($?, 'auth failure') if $? } |