diff --git a/ChangeLog b/ChangeLog index aa6e87d804..38e5e2d34f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Thu Mar 11 17:31:59 2010 Nobuyoshi Nakada + + * transcode.c (str_transcode0): confirm the code range. + Thu Mar 11 12:14:17 2010 Nobuyoshi Nakada * missing/signbit.c: added. diff --git a/transcode.c b/transcode.c index 9d6a886850..dba26a2394 100644 --- a/transcode.c +++ b/transcode.c @@ -2590,7 +2590,7 @@ str_transcode0(int argc, VALUE *argv, VALUE *self, int ecflags, VALUE ecopts) return NIL_P(arg2) ? -1 : dencidx; } if (senc && denc && rb_enc_asciicompat(senc) && rb_enc_asciicompat(denc)) { - if (ENC_CODERANGE(str) == ENC_CODERANGE_7BIT) { + if (rb_enc_str_coderange(str) == ENC_CODERANGE_7BIT) { return dencidx; } }