summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-08-06 06:20:43 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-08-06 06:20:43 +0000
commitfc2a1ad79f98544b46d07a18da48b27b75aef581 (patch)
treece8567f3821c98ccf6e730c457e345ca0ebbdb2f /string.c
parent616a47c5790887f6901801008ebbdce6705a1ca1 (diff)
* string.c (rb_str_rindex): must return -1 if unmatched.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r--string.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/string.c b/string.c
index e687fcc533..119852044e 100644
--- a/string.c
+++ b/string.c
@@ -912,6 +912,7 @@ rb_str_rindex(str, sub, pos)
}
s--;
}
+ return -1;
}
else {
return pos;