From f9cf141af97dff1d857ee2f905962a19ac97fc36 Mon Sep 17 00:00:00 2001 From: Father Chrysostomos Date: Fri, 20 Jan 2012 13:29:38 -0800 Subject: [PATCH] =?utf8?q?[perl=20#82772]=20utf8::decode:=20Don=E2=80=99t?= =?utf8?q?=20read=20past=20SvCUR?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- sv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sv.c b/sv.c index d116996..6e8ed66 100644 --- a/sv.c +++ b/sv.c @@ -3562,7 +3562,7 @@ Perl_sv_utf8_decode(pTHX_ register SV *const sv) * we want to make sure everything inside is valid utf8 first. */ c = start = (const U8 *) SvPVX_const(sv); - if (!is_utf8_string(c, SvCUR(sv)+1)) + if (!is_utf8_string(c, SvCUR(sv))) return FALSE; e = (const U8 *) SvEND(sv); while (c < e) { -- 2.7.4