perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Hay <steve.m....@googlemail.com.INVALID>
Subject Re: [RELEASE CANDIDATE] mod_perl-2.0.11 RC3
Date Thu, 03 Oct 2019 12:15:45 GMT
On Thu, 3 Oct 2019 at 10:14, Pete Houston <ph1@openstrike.co.uk> wrote:
>
> On Wed, Oct 02, 2019 at 06:07:39PM +0100, Steve Hay wrote:
> >
> > I'm not sure about this area, but if it works for with your patch then
> > it's probably an improvement :-)
> >
> > Just out of interest, does the following alternative patch work?
> >
> > Index: lib/Apache2/Resource.pm
> > ===================================================================
> > --- lib/Apache2/Resource.pm     (revision 1866274)
> > +++ lib/Apache2/Resource.pm     (working copy)
> > @@ -115,8 +115,7 @@
> >                    "</tr>");
> >
> >      for my $res (keys %$lim) {
> > -        my $val = eval "&BSD::Resource::${res}()";
> > -        my ($soft, $hard) = getrlimit $val;
> > +        my ($soft, $hard) = getrlimit($lim->{$res});
> >          (my $limit = $res) =~ s/^RLIMIT_//;
> >          ($soft, $hard) = ("$soft " . BM($soft), "$hard ". BM($hard))
> >              if $is_mb{$limit};
>
> Yes, that works just as well for me.
>
> > This avoids making the &BSD::Resource::${res}() calls, which are what
> > is returning undef for you in some cases. Or does this fail just the
> > same because some of the values of %$lim are also undef anyway?
>
> The %$lim values are not undef. See the attached stand-alone test and
> output for the problematic values which I see and which also shows that
> the limits for those resources are still retrievable via getrlimit().
>

Great! Thanks for confirming. I've now committed that fix, and hope to
make the final release soon: I don't think this single change warrants
an RC4.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message