Commit 4308f3c6 authored by Tomoyuki Sahara's avatar Tomoyuki Sahara

remove an always-true conditional.

parent b7049b39
......@@ -1805,7 +1805,7 @@ mrb_str_split_m(mrb_state *mrb, mrb_value str)
mrb_int idx = 0;
int ai = mrb_gc_arena_save(mrb);
while (idx < str_len && 1) {
while (idx < str_len) {
if (pat_len > 0) {
end = mrb_memsearch(RSTRING_PTR(spat), pat_len, RSTRING_PTR(str)+idx, str_len - idx);
if (end < 0) break;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment