Re: "perl -d" dumps core when loading syslog.ph
In article <m0x4ZGj-000EZYC@alias-2.pr.mcs.net>,
Stephen McCamant <alias@mcs.com> wrote:
> Jochen Wiedmann writes:
> > The following command dumps core on my machine:
> >
> > [joe@laptop joe]$ perl -d -MSys::Syslog
> > Signal SEGV at /sw/linux-i386/perl-5.004.03/lib/site_perl/syslog.ph
> > line 1
> > require syslog.ph called at
> > /sw/share/perl-5.004.03/lib/Sys/Syslog.pm line 111
> > [...]
> > IOT trap/Abort (core dumped)
> >
> > Without "-d" or without loading "syslog.ph" all works fine.
>
> This is almost certainly the same problem Greg Ward reported about a
> week ago:
>
> Greg Ward wrote:
> > In fact, I was able to reduce the bug to
> >
> > % perl -d -e "BEGIN { eval 'sub LOG_KERN () {0<<3;}' }"
>
> I still haven't seen anything from Ilya (whose reply was apparently
> lost in the UPenn changeover), so in the spirit of needing it twice,
> here's a patch:
>
> --- perl5.004_02/pp_ctl.c Sat Aug 9 00:11:51 1997
> +++ perl5.004_02+/pp_ctl.c Fri Aug 29 16:51:36 1997
> @@ -2104,7 +2104,7 @@
Lemme try again. In my missing message I explained that the same
problem may hunt my (?{...}) stuff for regexps.
I removed the monstrous patch proposed in the previous message, here
is the alternative:
Credited: Stephen McCamant <alias@mcs.com>
p5p-msgid: 1997Aug30.034921.2297381@cor.newman.upenn.edu