This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
toke.c: Make _charnames check more robust
authorFather Chrysostomos <sprout@cpan.org>
Thu, 6 Dec 2012 07:10:25 +0000 (23:10 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Sun, 9 Dec 2012 02:44:28 +0000 (18:44 -0800)
commit67a057d6d88eb9aafa609d47fefa412673b99ff5
treed903dc98f78ef87e6af2c0b80e4c39dff6c1cd65
parente3fdfe77a69de5c9746593dc75431d53cef4c9f4
toke.c: Make _charnames check more robust

Assuming that $^H{charnames} exists and contains a code ref can result
in crashes.  See the tests in the diff.

It’s not a good idea to do $INC{"_charnames.pm"}++, but perl still
shouldn’t crash.
t/op/lex.t
toke.c