summaryrefslogtreecommitdiffstats
path: root/test/ruby/test_marshal.rb
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-25 14:45:39 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-25 14:45:39 +0000
commit13fee949b6b8905a0a64b8ad6879c0f573243c4a (patch)
tree820599a3835d4f81f3a948ef9bc0aebaecbbb9b9 /test/ruby/test_marshal.rb
parent4a4ac19fc5775c7ee0d58f68c4abac994d0467ef (diff)
merges r24443 from trunk into ruby_1_9_1.
-- * marshal.c (w_symbol r_symlink, r_symbol, r_object0): fix for non-ascii symbols. loading such symbols can cause segfaults in older versions. [ruby-core:24788] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@25473 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_marshal.rb')
-rw-r--r--test/ruby/test_marshal.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_marshal.rb b/test/ruby/test_marshal.rb
index 268acf2a3..4a9192d44 100644
--- a/test/ruby/test_marshal.rb
+++ b/test/ruby/test_marshal.rb
@@ -192,4 +192,10 @@ class TestMarshal < Test::Unit::TestCase
assert_equal(true, y.tainted?)
assert_equal(true, y.untrusted?)
end
+
+ def test_symbol
+ [:ruby, :"\u{7d05}\u{7389}"].each do |sym|
+ assert_equal(sym, Marshal.load(Marshal.dump(sym)), '[ruby-core:24788]')
+ end
+ end
end