summaryrefslogtreecommitdiff
path: root/doop.c
diff options
context:
space:
mode:
Diffstat (limited to 'doop.c')
-rw-r--r--doop.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/doop.c b/doop.c
index 9f0fa6466a..0c7abf46ca 100644
--- a/doop.c
+++ b/doop.c
@@ -697,6 +697,8 @@ Perl_do_sprintf(pTHX_ SV *sv, I32 len, SV **sarg)
char *pat = SvPV(*sarg, patlen);
bool do_taint = FALSE;
+ if (DO_UTF8(*sarg))
+ SvUTF8_on(sv);
sv_vsetpvfn(sv, pat, patlen, Null(va_list*), sarg + 1, len - 1, &do_taint);
SvSETMAGIC(sv);
if (do_taint)