This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
In pp_sys.c:pp_fttext, don’t call cGVOP_gv on an UNOP
authorFather Chrysostomos <sprout@cpan.org>
Thu, 12 Jan 2012 20:55:21 +0000 (12:55 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Thu, 12 Jan 2012 20:55:59 +0000 (12:55 -0800)
commit3f12cff414d1c6ec878a7e1a4ed270a421a8a75e
treee683d17d246a62dc3e6a37ce6a3973d2d7560fed
parenta289ef89aea304cdebfa085e4451b1c02cb33648
In pp_sys.c:pp_fttext, don’t call cGVOP_gv on an UNOP

Otherwise we might get a crash.  cGVOP_gv is only valid when the
OPf_REF flag is set.  In either case, gv already holds the GV we
want anyway.

This code has been buggy this way since this commit:

commit 5f05dabc4054964aa3b10f44f8468547f051cdf8
Author: Perl 5 Porters <perl5-porters@africa.nicoh.com>
Date:   Thu Dec 19 16:44:00 1996 +1200

    [inseparable changes from patch from perl5.003_11 to perl5.003_12]

but apparently has not actually caused a crash until just now.

I was trying to add a test for another bug (fixed in the next commit),
and it happened to trigger this one.  My attempt to reduce this to
something small and reproducible failed.
pp_sys.c