This bug is still present in perl-5.9.1
(Sorry it took me so long to install enough CPAN modules to reproduce it ;-)
Applying the patch referenced below fixes the problem.
I recommend that you make sure this patch gets applied to 5.9.2 or whatever the next release is going to be! Thank you
- - Martin
> -----Original Message-----
> From: Dave Mitchell [mailto:davem@fdisolutions.com]
> Sent: Wednesday, March 24, 2004 16:08
> To: Thurn, Martin
> Cc: 'perlbug-followup@perl.org'
> Subject: Re: [perl #27769] perl-5.9.0 SegFault during cpan> r
>
>
> On Wed, Mar 24, 2004 at 07:51:49AM -0800, Thurn, Martin wrote:
> > > Do you mean you have >2397 CPAN modules installed locally? If
> > > so, it going
> > > to be a bit of a pain to reproduce locally here.
> >
> > Sorry I'm a CPAN junkie ;-) Yes indeed I have more than 10,000 .pm
> > files under /usr/local/lib/perl5...
>
> The mind boggles ;-)
>
> Rafael has applied a patch to bleedperl which guards against
> a certain null
> pointer being dereferenced. I've included it below in case you want to
> try it againt 5.9.0. I suspect it will cure your problem, since in
> particular, version object magic has that null pointer, and
> you said it
> crashed when it was evaling the $VERSION strings of modules.
>
> Dave.
>
> --
> Please note that ash-trays are provided for the use of smokers,
> whereas the floor is provided for the use of all patrons.
> -- Bill Royston
>
>
> Change 22578 by rgs@rgs-home on 2004/03/24 13:54:31
>
> Good catch from Dave Mitchell; plus a null pointer protection.
>
> Affected files ...
>
> ... //depot/perl/scope.c#121 edit
>
> Differences ...
>
> ==== //depot/perl/scope.c#121 (text) ====
> Index: perl/scope.c
> --- perl/scope.c#120~22509~ Tue Mar 16 10:19:52 2004
> +++ perl/scope.c Wed Mar 24 05:54:31 2004
> @@ -217,8 +217,8 @@
> /* if it's a special scalar or if it has no 'set' magic,
> * propagate the SvREADONLY flag. --rgs 20030922 */
> for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
> - if (SvMAGIC(sv)->mg_type == '\0'
> - || !SvMAGIC(sv)->mg_virtual->svt_set)
> + if (mg->mg_type == '\0'
> + || !(mg->mg_virtual && mg->mg_virtual->svt_set))
> {
> SvFLAGS(sv) |= SvREADONLY(osv);
> break;
> End of Patch.
>
Thread Next