From 8d7145a4eb80b9e92354f2fbb2e142b32d8eeafc Mon Sep 17 00:00:00 2001 From: matz Date: Mon, 8 Jan 2007 20:11:40 +0000 Subject: * string.c (rb_str_upto): use RSTRING_LEN(). git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11516 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- string.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'string.c') diff --git a/string.c b/string.c index 49eddf614..804614517 100644 --- a/string.c +++ b/string.c @@ -1568,7 +1568,7 @@ rb_str_upto(VALUE beg, VALUE end, int excl) StringValue(current); if (excl && rb_str_equal(current, end)) break; StringValue(current); - if (RSTRING_LEN(current) > RSTRING_LEN(end) || RSTRING(current)->len == 0) + if (RSTRING_LEN(current) > RSTRING_LEN(end) || RSTRING_LEN(current) == 0) break; } -- cgit