summaryrefslogtreecommitdiffhomepage
path: root/src/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/string.c')
-rw-r--r--src/string.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/string.c b/src/string.c
index 257286144..3677da0ab 100644
--- a/src/string.c
+++ b/src/string.c
@@ -635,7 +635,6 @@ mrb_str_index(mrb_state *mrb, mrb_value str, mrb_value sub, mrb_int offset)
slen = RSTRING_LEN(sub);
len = RSTRING_LEN(str) - offset;
pos = mrb_memsearch(sptr, slen, s, len);
-
if (pos < 0) return pos;
return pos + offset;
}