mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-23 12:22:26 +00:00
First delete the blocks, THEN the locals, since blocks USE locals, darn
This commit is contained in:
parent
6145ecf7e0
commit
eef92df092
1 changed files with 3 additions and 3 deletions
6
ast.c
6
ast.c
|
@ -169,12 +169,12 @@ MEM_VEC_FUNCTIONS(ast_block, ast_expression*, exprs)
|
|||
void ast_block_delete(ast_block *self)
|
||||
{
|
||||
size_t i;
|
||||
for (i = 0; i < self->locals_count; ++i)
|
||||
ast_delete(self->locals[i]);
|
||||
MEM_VECTOR_CLEAR(self, locals);
|
||||
for (i = 0; i < self->exprs_count; ++i)
|
||||
ast_unref(self->exprs[i]);
|
||||
MEM_VECTOR_CLEAR(self, exprs);
|
||||
for (i = 0; i < self->locals_count; ++i)
|
||||
ast_delete(self->locals[i]);
|
||||
MEM_VECTOR_CLEAR(self, locals);
|
||||
mem_d(self);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue