This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regexec.c: Guard against malformed UTF-8 in [...]
authorKarl Williamson <public@khwilliamson.com>
Wed, 1 Jan 2014 16:59:20 +0000 (09:59 -0700)
committerKarl Williamson <public@khwilliamson.com>
Wed, 1 Jan 2014 18:50:37 +0000 (11:50 -0700)
commit3db24e1e3c8c10bf892a8f48ff3d780fdd1f88a0
tree2bccba493a992a746670af29c5523f1fde57de97
parentf3943cf2ca1b7a02583ef8bbeb1ced9414bf1fac
regexec.c: Guard against malformed UTF-8 in [...]

The code that handles bracketed character classes assumed that the
string being matched against did not have the too-short malformation;
this could lead to reading beyond-the-end-of-buffer.  (It did check for
other malformations.)  This is solved by changing the function that
operates on bracketed character classes to take and use an extra
parameter, the actaul buffer end.
embed.fnc
embed.h
proto.h
regexec.c