summaryrefslogtreecommitdiff
path: root/test/zlib
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-10-21 12:56:48 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-10-21 12:56:48 +0000
commit42a6550027acfae936ba4038ca3b2a3e5ed479b2 (patch)
treea45b61004977fc8f10e1906bc4ad2c7f6a21595c /test/zlib
parentac466de7ff7bb62f86e2252d479d9db8c1f98500 (diff)
* ext/zlib/zlib.c (rb_gzwriter_write): conversion should be done
using to_str, not to_s. * ext/zlib/zlib.c (rb_gzwriter_write): need proper conversion according to gz encoding. * ext/zlib/zlib.c (rb_gzreader_ungetc): convert string encoding before unget. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19872 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/zlib')
-rw-r--r--test/zlib/test_zlib.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/zlib/test_zlib.rb b/test/zlib/test_zlib.rb
index 5746f036ea..5a4a87a0fb 100644
--- a/test/zlib/test_zlib.rb
+++ b/test/zlib/test_zlib.rb
@@ -597,7 +597,7 @@ if defined? Zlib
assert_equal("foo", Zlib::GzipReader.open(t.path) {|gz| gz.read })
o = Object.new
- def o.to_s; "bar"; end
+ def o.to_str; "bar"; end
Zlib::GzipWriter.open(t.path) {|gz| gz.print(o) }
assert_equal("bar", Zlib::GzipReader.open(t.path) {|gz| gz.read })
end