This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
sub NEGATIVE_INDICES; + $tied[-1] = crash
authorFather Chrysostomos <sprout@cpan.org>
Sun, 3 Nov 2013 12:47:17 +0000 (04:47 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Mon, 4 Nov 2013 13:10:18 +0000 (05:10 -0800)
commit7274b33cb1232fb4911cb441bae8e0abebf734f2
treed76bed36f2eb81d720f04346a3c5d2d92367f5fb
parentca58dfd9e0b19f1ae344f4aea62e3e4193f9c34f
sub NEGATIVE_INDICES; + $tied[-1] = crash

This code in av.c, when trying to find $NEGATIVE_INDICES, was doing a
direct stash element lookup--instead of going through the normal GV
functions--and then expecting the returned value to be a GV.

‘sub NEGATIVE_INDICES’ creates a stash element that is a PV, not a GV,
so it’s easy to make things crash.
av.c
t/op/tie.t