diff options
| author | Bouke van der Bijl <[email protected]> | 2016-11-14 17:28:18 -0500 |
|---|---|---|
| committer | Bouke van der Bijl <[email protected]> | 2016-11-24 10:20:42 -0500 |
| commit | 71641bbf732ab8cbadf8a07e20b2a939b0e3b82b (patch) | |
| tree | 1b2aa3eb2d4ab2fbab4c11da633fa0657a3afdff /test/t/codegen.rb | |
| parent | a630c4f413f6af764e68210430e8b61a435d38d7 (diff) | |
| download | mruby-71641bbf732ab8cbadf8a07e20b2a939b0e3b82b.tar.gz mruby-71641bbf732ab8cbadf8a07e20b2a939b0e3b82b.zip | |
Fix segfault caused by empty condition in ternary
Reported by https://hackerone.com/jpenalbae
Diffstat (limited to 'test/t/codegen.rb')
| -rw-r--r-- | test/t/codegen.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/t/codegen.rb b/test/t/codegen.rb new file mode 100644 index 000000000..99d6dbe66 --- /dev/null +++ b/test/t/codegen.rb @@ -0,0 +1,6 @@ +## +# Codegen tests + +assert('empty condition in ternary expression parses correctly') do + assert_equal () ? 1 : 2, 2 +end |
