diff options
author | Eric Wong <e@80x24.org> | 2021-09-03 08:54:24 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-09-03 08:57:34 +0000 |
commit | 059f92ef0d66677cce0b0d011748f7fcc1697a51 (patch) | |
tree | 05f0f227f3372b212fe871c2c2e44e1938696faa /lib/PublicInbox/LeiUp.pm | |
parent | 7e29f0aa79e3e559379ebfa8bb8b17eabdb6db1a (diff) | |
download | public-inbox-059f92ef0d66677cce0b0d011748f7fcc1697a51.tar.gz |
This is merely to avoid perl setting errors internally which were not user visible. The double-close wasn't a problem in practice since we open a new file hanlde for the mbox or mbox.gz anyways, so the new t/lei-up.t test case shows no regressions nor fixes.
Diffstat (limited to 'lib/PublicInbox/LeiUp.pm')
-rw-r--r-- | lib/PublicInbox/LeiUp.pm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/PublicInbox/LeiUp.pm b/lib/PublicInbox/LeiUp.pm index e1da64aa..a39d6047 100644 --- a/lib/PublicInbox/LeiUp.pm +++ b/lib/PublicInbox/LeiUp.pm @@ -54,6 +54,10 @@ sub up1_redispatch { $l->{opt} = { %{$l->{opt}} }; delete $l->{sock}; $l->{''} = $op_p; # daemon only + + # make close($l->{1}) happy in lei->dclose + open my $fh, '>&', $l->{1} or return $l->child_error(0, "dup: $!"); + $l->{1} = $fh; eval { $l->qerr("# updating $out"); up1($l, $out); |