From 9ff1f777cda255d8c9b9224b69241aad7c297db5 Mon Sep 17 00:00:00 2001 From: "Eric Wong (Contractor, The Linux Foundation)" Date: Fri, 23 Feb 2018 02:26:45 +0000 Subject: v2writable: cleanup unused pipes in partitions Leaking these pipes to child processes wasn't harmful, but made determining relationships and dataflow between processes more confusing. --- lib/PublicInbox/Import.pm | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lib/PublicInbox/Import.pm') diff --git a/lib/PublicInbox/Import.pm b/lib/PublicInbox/Import.pm index b650e4ef..ac46c0cb 100644 --- a/lib/PublicInbox/Import.pm +++ b/lib/PublicInbox/Import.pm @@ -372,6 +372,13 @@ sub done { close $lockfh or die "close lock failed: $!"; } +sub atfork_child { + my ($self) = @_; + foreach my $f (qw(in out)) { + close $self->{$f} or die "failed to close import[$f]: $!\n"; + } +} + 1; __END__ =pod -- cgit v1.2.3-24-ge0c7