summaryrefslogtreecommitdiff
path: root/encoding.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-03-18 05:26:07 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-03-18 05:26:07 +0000
commit58f269d070fb404f7e78ee7153a01462ab87bdb9 (patch)
tree0ed5dc8495b5b0997212b09da6f750fae08dd4ef /encoding.c
parent815d88b569d9b2ceb480c7ce76b429257199a5c7 (diff)
merge revision(s) 34433: [Backport #6153]
* encoding.c (rb_enc_compatible): return ASCII-8BIT even if 2nd string is ascii only string. [ruby-core:42354] [Bug #5968] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@35078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'encoding.c')
-rw-r--r--encoding.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/encoding.c b/encoding.c
index 18f54e684c..b8c5f6d357 100644
--- a/encoding.c
+++ b/encoding.c
@@ -804,7 +804,6 @@ rb_enc_compatible(VALUE str1, VALUE str2)
if (cr2 == ENC_CODERANGE_7BIT) return enc1;
}
if (cr2 == ENC_CODERANGE_7BIT) {
- if (idx1 == ENCINDEX_ASCII) return enc2;
return enc1;
}
}