summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-13 06:13:10 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-13 06:13:10 +0000
commitb77f3c6d2bebe7e313fdd5aba34c525d56f46680 (patch)
tree50dad966b84bc2082a8d32783b8ede460a5e1a39
parentce1106a1711e45d46093681702ff95e7e484f6cf (diff)
downloadruby-b77f3c6d2bebe7e313fdd5aba34c525d56f46680.tar.gz
ruby-b77f3c6d2bebe7e313fdd5aba34c525d56f46680.tar.xz
ruby-b77f3c6d2bebe7e313fdd5aba34c525d56f46680.zip
merges r23976 from trunk into ruby_1_9_1.
-- * io.c (rb_io_ext_int_to_encs): Set external encoding if ext==intern. [ruby-dev:38278] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@24071 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--io.c2
-rw-r--r--version.h2
3 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index f4a21f4c2..4b74c4c05 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Tue Jul 7 10:12:37 2009 NARUSE, Yui <naruse@ruby-lang.org>
+
+ * io.c (rb_io_ext_int_to_encs): Set external encoding if
+ ext==intern. [ruby-dev:38278]
+
Mon Jul 6 08:00:10 2009 Yukihiro Matsumoto <matz@ruby-lang.org>
* enum.c (enum_to_a): should propagate taint to the return value.
diff --git a/io.c b/io.c
index bb3daf0f0..7c77358d7 100644
--- a/io.c
+++ b/io.c
@@ -3868,7 +3868,7 @@ rb_io_ext_int_to_encs(rb_encoding *ext, rb_encoding *intern, rb_encoding **enc,
intern = rb_default_internal_encoding();
if (intern == NULL || intern == (rb_encoding *)Qnil || intern == ext) {
/* No internal encoding => use external + no transcoding */
- *enc = default_ext ? NULL : ext;
+ *enc = (default_ext && intern != ext) ? NULL : ext;
*enc2 = NULL;
}
else {
diff --git a/version.h b/version.h
index 7ca43543b..87a9bea34 100644
--- a/version.h
+++ b/version.h
@@ -1,6 +1,6 @@
#define RUBY_VERSION "1.9.1"
#define RUBY_RELEASE_DATE "2009-07-12"
-#define RUBY_PATCHLEVEL 221
+#define RUBY_PATCHLEVEL 222
#define RUBY_VERSION_MAJOR 1
#define RUBY_VERSION_MINOR 9
#define RUBY_VERSION_TEENY 1