]> de.git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - ast.c
process_condition function used by parse_if - need to still add it to loops
[xonotic/gmqcc.git] / ast.c
diff --git a/ast.c b/ast.c
index cbcfb09d624ab227610a02f03eebfbb9a8a717db..79a74c0cc0176fce28f91ddc18cc4021f79b33e3 100644 (file)
--- a/ast.c
+++ b/ast.c
@@ -476,7 +476,7 @@ ast_unary* ast_unary_new(lex_ctx ctx, int op,
 
 void ast_unary_delete(ast_unary *self)
 {
-    ast_unref(self->operand);
+    if (self->operand) ast_unref(self->operand);
     ast_expression_delete((ast_expression*)self);
     mem_d(self);
 }