mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-03-21 10:21:03 +00:00
initialize max_param_count to 1 so vararg functions don't try to create an accessor for an array of 0 elements...
This commit is contained in:
parent
dfad837f5b
commit
0ba8455f6a
1 changed files with 2 additions and 0 deletions
2
parser.c
2
parser.c
|
@ -5708,6 +5708,8 @@ bool parser_init()
|
|||
if (OPTS_FLAG(UNTYPED_NIL))
|
||||
util_htset(parser->htglobals, "nil", (void*)parser->nil);
|
||||
|
||||
parser->max_param_count = 1;
|
||||
|
||||
parser->const_vec[0] = ast_value_new(empty_ctx, "<vector.x>", TYPE_NOEXPR);
|
||||
parser->const_vec[1] = ast_value_new(empty_ctx, "<vector.y>", TYPE_NOEXPR);
|
||||
parser->const_vec[2] = ast_value_new(empty_ctx, "<vector.z>", TYPE_NOEXPR);
|
||||
|
|
Loading…
Reference in a new issue