aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-02-06 04:48:49 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-02-06 04:48:49 +0000
commitb5f628a84aa42724a01d6ad97abac46f857ff08b (patch)
treea1e5d34c594fb969c78d279d65c87c15eb5a6458
parentedaf78dfb69db9794e4ddf4f0a658c374e857924 (diff)
downloadruby-b5f628a84aa42724a01d6ad97abac46f857ff08b.tar.gz
* ext/json/lib/json/common.rb (JSON::MissingUnicodeSupport.iconv):
should not drop rest of the result. use Iconv.conv instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30807 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--ext/json/lib/json/common.rb2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index b5931cf4b0..9a01eebd0d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun Feb 6 13:48:29 2011 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * ext/json/lib/json/common.rb (JSON::MissingUnicodeSupport.iconv):
+ should not drop rest of the result. use Iconv.conv instead.
+
Sun Feb 6 12:46:02 2011 Eric Hodel <drbrain@segment7.net>
* string.c (gsub): Ensure result encoding is the same as input
diff --git a/ext/json/lib/json/common.rb b/ext/json/lib/json/common.rb
index 13debd1366..91cb3c2190 100644
--- a/ext/json/lib/json/common.rb
+++ b/ext/json/lib/json/common.rb
@@ -348,7 +348,7 @@ module JSON
else
require 'iconv'
def self.iconv(to, from, string)
- Iconv.iconv(to, from, string).first
+ Iconv.conv(to, from, string)
end
end
end