summaryrefslogtreecommitdiff
path: root/pp.c
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2019-03-18 10:29:46 -0600
committerKarl Williamson <khw@cpan.org>2019-03-19 10:24:28 -0600
commitcf70d9e66cc428b97f59d1cca621579346948015 (patch)
treeea699cedbc9eadb86a676e533a8d8eee7cf384c7 /pp.c
parent52bcf2657b8c6ee52d2eeb841fc2607db893f58f (diff)
downloadperl-cf70d9e66cc428b97f59d1cca621579346948015.tar.gz
pp.c: Use safer utf8_hop
Diffstat (limited to 'pp.c')
-rw-r--r--pp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pp.c b/pp.c
index 42b111ea32..1d83b08e9b 100644
--- a/pp.c
+++ b/pp.c
@@ -6246,7 +6246,7 @@ PP(pp_split)
/* The rx->minlen is in characters but we want to step
* s ahead by bytes. */
if (do_utf8)
- s = (char*)utf8_hop((U8*)m, len);
+ s = (char*)utf8_hop_forward((U8*) m, len, (U8*) strend);
else
s = m + len; /* Fake \n at the end */
}
@@ -6270,7 +6270,7 @@ PP(pp_split)
/* The rx->minlen is in characters but we want to step
* s ahead by bytes. */
if (do_utf8)
- s = (char*)utf8_hop((U8*)m, len);
+ s = (char*)utf8_hop_forward((U8*)m, len, (U8 *) strend);
else
s = m + len; /* Fake \n at the end */
}