This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #127334] S_incline: avoid overrunning the end of the parse buffer
authorTony Cook <tony@develop-help.com>
Wed, 10 Feb 2016 05:03:22 +0000 (16:03 +1100)
committerTony Cook <tony@develop-help.com>
Wed, 10 Feb 2016 05:03:22 +0000 (16:03 +1100)
commit1bb1a3d6d354f67d1158693a799cb49037d27475
treecffe52565e744987fe8be1dc69a136cafce52e42
parent0000ba0df5a44d6aa7d7e7942b90493bfa7d5b45
[perl #127334] S_incline: avoid overrunning the end of the parse buffer

If the rest of the allocation up to the end addressable memory was
non-spaces, this loop could cause a segmentation fault.

Avoid that by ensuring we stop when we see a NUL.
toke.c