From 8c19ecbeeb846e254df520b9e339c36a42277ceb Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 10 Oct 2007 05:31:08 +0000 Subject: * string.c (rb_enc_str_coderange): fixed checkfor non-ascii. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13669 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 8210f8dcbc..4969b7513f 100644 --- a/string.c +++ b/string.c @@ -117,7 +117,7 @@ rb_enc_str_coderange(VALUE str) while (p < e) { int c = (unsigned char)*p; - if (c > 0x80) { + if (!isascii(c)) { cr = ENC_CODERANGE_MULTI; break; } -- cgit v1.2.3