diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-04-13 07:41:24 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-04-13 07:41:24 +0000 |
commit | 485267354273fc2ca2c9b1f22e39c5f1f414f4ca (patch) | |
tree | e5f250f60ef664363107833593389c37bad852f8 /parse.y | |
parent | ab4c4d3e2b293cb40ca6a5f2a233ae3b5747e184 (diff) |
merge revision(s) 50265: [Backport #10957]
* parse.y (arg): fix segfault by null caused by syntax error.
[ruby-core:68851] [Bug #10957]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_1@50283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r-- | parse.y | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -2047,7 +2047,7 @@ arg : lhs '=' arg value_expr($3); $$ = NEW_DOT2($1, $3); if ($1 && nd_type($1) == NODE_LIT && FIXNUM_P($1->nd_lit) && - nd_type($3) == NODE_LIT && FIXNUM_P($3->nd_lit)) { + $3 && nd_type($3) == NODE_LIT && FIXNUM_P($3->nd_lit)) { deferred_nodes = list_append(deferred_nodes, $$); } /*% @@ -2061,7 +2061,7 @@ arg : lhs '=' arg value_expr($3); $$ = NEW_DOT3($1, $3); if ($1 && nd_type($1) == NODE_LIT && FIXNUM_P($1->nd_lit) && - nd_type($3) == NODE_LIT && FIXNUM_P($3->nd_lit)) { + $3 && nd_type($3) == NODE_LIT && FIXNUM_P($3->nd_lit)) { deferred_nodes = list_append(deferred_nodes, $$); } /*% |