summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'string.c')
-rw-r--r--string.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/string.c b/string.c
index a9b8eedbe8..7b8c558c11 100644
--- a/string.c
+++ b/string.c
@@ -2055,7 +2055,7 @@ rb_str_split_method(argc, argv, str)
if (!NIL_P(limit) && lim <= ++i) break;
}
end++;
- if (ismbchar(*ptr)) ptr++;
+ if (ismbchar(*ptr)) {ptr++; end++;}
}
}
}