mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-03-22 10:41:43 +00:00
ast_member will not unref/delete the owner: first of all the owner is always an ast_value, which won't get deleted anyway, secondly: the ast_members are collected and deleted after the owners, so ast_unref(owner) will cause invalid memory access
This commit is contained in:
parent
b6ab0207b1
commit
ffd41cb1c7
1 changed files with 1 additions and 1 deletions
2
ast.c
2
ast.c
|
@ -405,7 +405,7 @@ ast_member* ast_member_new(lex_ctx ctx, ast_expression *owner, unsigned int fiel
|
|||
|
||||
void ast_member_delete(ast_member *self)
|
||||
{
|
||||
ast_unref(self->owner);
|
||||
// ast_unref(self->owner);
|
||||
ast_expression_delete((ast_expression*)self);
|
||||
mem_d(self);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue