diff options
author | Eric Wong <e@80x24.org> | 2019-09-17 08:31:19 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2019-09-17 08:31:42 +0000 |
commit | 641191aa902bb3259a13d0f348b78a49aafe4902 (patch) | |
tree | 7e74bac55452c206fc91cbd449cb8218230d8140 /lib | |
parent | 7227d5882471e32858e460043e2dd69b4a926d4a (diff) | |
download | public-inbox-641191aa902bb3259a13d0f348b78a49aafe4902.tar.gz |
Generic PSGI servers have $env->{'psgi.errors'}, too, so ensure they can log errors.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/PublicInbox/Qspawn.pm | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/PublicInbox/Qspawn.pm b/lib/PublicInbox/Qspawn.pm index 6b350f0f..844d50f7 100644 --- a/lib/PublicInbox/Qspawn.pm +++ b/lib/PublicInbox/Qspawn.pm @@ -116,10 +116,9 @@ sub waitpid_err ($$) { sub do_waitpid ($;$) { my ($self, $env) = @_; my $pid = $self->{pid}; - eval { # PublicInbox::DS may not be loaded - PublicInbox::DS::dwaitpid($pid, \&waitpid_err, $self); - $self->{env} = $env; - }; + $self->{env} = $env; + # PublicInbox::DS may not be loaded + eval { PublicInbox::DS::dwaitpid($pid, \&waitpid_err, $self) }; # done if we're running in PublicInbox::DS::EventLoop if ($@) { # non public-inbox-{httpd,nntpd} callers may block: |