diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-10 08:45:34 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-10 08:45:34 +0000 |
commit | 1a7e21943307a21cc3a70237a85ff7205d6dcd53 (patch) | |
tree | ca0f745ebfca1aa3c6f3e9c008f53eb5def2ac68 /test | |
parent | a05bfd49410bedb5812f8f4e4c27eb1bcd15211e (diff) |
merge revision(s) 55163,55165: [Backport #12420] [Backport #12423]
* regparse.c (fetch_token_in_cc): raise error if given octal escaped
character is too big. [Bug #12420] [Bug #12423]
* re.c (unescape_nonascii): scan hex up to only 3 characters.
[Bug #12420] [Bug #12423]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_regexp.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ruby/test_regexp.rb b/test/ruby/test_regexp.rb index cc1444c924..321a1989c2 100644 --- a/test/ruby/test_regexp.rb +++ b/test/ruby/test_regexp.rb @@ -388,6 +388,8 @@ class TestRegexp < Test::Unit::TestCase assert_equal(arg_encoding_none, Regexp.new("", nil, "N").options) assert_raise(RegexpError) { Regexp.new(")(") } + assert_raise(RegexpError) { Regexp.new('[\\40000000000') } + assert_raise(RegexpError) { Regexp.new('[\\600000000000.') } end def test_unescape |