summaryrefslogtreecommitdiff
path: root/extmod/modure.c
diff options
context:
space:
mode:
Diffstat (limited to 'extmod/modure.c')
-rw-r--r--extmod/modure.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/extmod/modure.c b/extmod/modure.c
index 59fbfddbf..799fef13b 100644
--- a/extmod/modure.c
+++ b/extmod/modure.c
@@ -373,7 +373,7 @@ STATIC mp_obj_t re_sub_helper(size_t n_args, const mp_obj_t *args) {
vstr_add_strn(&vstr_return, subj.begin, subj.end - subj.begin);
if (mp_obj_get_type(where) == &mp_type_str) {
- return mp_obj_new_str_from_vstr(&vstr_return);
+ return mp_obj_new_str_from_utf8_vstr(&vstr_return);
} else {
return mp_obj_new_bytes_from_vstr(&vstr_return);
}