]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/LeiXSearch.pm
lei_xsearch: load PublicInbox::Smsg
[public-inbox.git] / lib / PublicInbox / LeiXSearch.pm
index de82a7daee1d4b5a20227e3f4819bc69d330cacb..4d390ee4661444d403ad3f45fdcbb7b32868a3fb 100644 (file)
@@ -16,6 +16,7 @@ use File::Spec ();
 use PublicInbox::Search qw(xap_terms);
 use PublicInbox::Spawn qw(popen_rd spawn which);
 use PublicInbox::MID qw(mids);
+use PublicInbox::Smsg;
 use Fcntl qw(SEEK_SET F_SETFL O_APPEND O_RDWR);
 
 sub new {
@@ -283,7 +284,7 @@ sub query_done { # EOF callback
        my $has_l2m = exists $lei->{l2m};
        for my $f (qw(lxs l2m)) {
                my $wq = delete $lei->{$f} or next;
-               $wq->wq_wait_old;
+               $wq->wq_wait_old($lei);
        }
        $lei->{ovv}->ovv_end($lei);
        if ($has_l2m) { # close() calls LeiToMail reap_compress
@@ -359,7 +360,7 @@ sub sigpipe_handler { # handles SIGPIPE from l2m/lxs workers
        my ($lei) = @_;
        my $lxs = delete $lei->{lxs};
        if ($lxs && $lxs->wq_kill_old) { # is this the daemon?
-               $lxs->wq_wait_old;
+               $lxs->wq_wait_old($lei);
        }
        close(delete $lei->{1}) if $lei->{1};
        $lei->x_it(13);