From eb8ddac5e27c718af6ddca6185eddadd94faf59b Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Thu, 5 Dec 2024 10:37:05 -0700 Subject: [PATCH] utf8n_to_uvuni: Use utf8_to_uv() This is the preferred function --- mathoms.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mathoms.c b/mathoms.c index 402f3a3e32b8..5c1b77d04572 100644 --- a/mathoms.c +++ b/mathoms.c @@ -199,7 +199,9 @@ Perl_utf8n_to_uvuni(pTHX_ const U8 *s, STRLEN curlen, STRLEN *retlen, U32 flags) { PERL_ARGS_ASSERT_UTF8N_TO_UVUNI; - return NATIVE_TO_UNI(utf8n_to_uvchr(s, curlen, retlen, flags)); + UV cp; + utf8_to_uv_flags(s, s + curlen, &cp, retlen, flags); + return NATIVE_TO_UNI(cp); } UV