]> Sergey Matveev's repositories - public-inbox.git/commitdiff
lei: drop circular reference in lei_store process
authorEric Wong <e@80x24.org>
Wed, 24 Mar 2021 09:23:29 +0000 (14:23 +0500)
committerEric Wong <e@80x24.org>
Wed, 24 Mar 2021 23:01:17 +0000 (23:01 +0000)
I'm not sure if this was causing real problems, but it's sure ugly.

lib/PublicInbox/LEI.pm

index 8cbaac015d4caee8d96d4d65bdf91b300fe23b4c..ee991f809e3a2fcbefb85a52e75ac33f2766b61d 100644 (file)
@@ -458,6 +458,9 @@ sub _lei_atfork_child {
                unless ($self->{oneshot}) {
                        close($_) for @io;
                }
+               if (my $cfg = $self->{cfg}) {
+                       delete $cfg->{-lei_store};
+               }
        } else { # worker, Net::NNTP (Net::Cmd) uses STDERR directly
                open STDERR, '+>&='.fileno($self->{2}) or warn "open $!";
                delete $self->{0};