diff options
author | Karl Williamson <public@khwilliamson.com> | 2014-03-12 14:11:58 -0600 |
---|---|---|
committer | Karl Williamson <public@khwilliamson.com> | 2014-03-12 14:32:36 -0600 |
commit | 8842e230bdaeef0ab4af48b7d7a9b29ee40b3890 (patch) | |
tree | bf7aae8012cfb9fd7c9072bedf942f3a18463df2 /regcomp.c | |
parent | 5d9574c10ca04dcefc1cac5441cb321f7bb4cc37 (diff) | |
download | perl-8842e230bdaeef0ab4af48b7d7a9b29ee40b3890.tar.gz |
regcomp.c: Don't read past string-end
In doing an audit of regcomp.c, and experimenting using
Encode::_utf8_on(), I found this one instance of a regen/regcharclass.pl
macro that could read beyond the end of the string if given malformed
UTF-8. Hence we convert to use the 'safe' form. There are no other
uses of the non-safe version, so don't need to generate them.
Diffstat (limited to 'regcomp.c')
-rw-r--r-- | regcomp.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -11920,7 +11920,7 @@ tryagain: if (! SIZE_ONLY && RExC_flags & RXf_PMf_EXTENDED && ckWARN_d(WARN_DEPRECATED) - && is_PATWS_non_low(p, UTF)) + && is_PATWS_non_low_safe(p, RExC_end, UTF)) { vWARN_dep(p + ((UTF) ? UTF8SKIP(p) : 1), "Escape literal pattern white space under /x"); |