]> git.xonotic.org Git - xonotic/gmqcc.git/commitdiff
set expression.next to NULL in ast_block_set_type if it won't be set to a new value
authorWolfgang (Blub) Bumiller <blub@speed.at>
Sat, 18 Aug 2012 15:46:02 +0000 (17:46 +0200)
committerWolfgang (Blub) Bumiller <blub@speed.at>
Sat, 18 Aug 2012 15:46:02 +0000 (17:46 +0200)
ast.c

diff --git a/ast.c b/ast.c
index 52023ff27004b5c26863861fb9e46948b7c0107a..851171ef50798a697f0a8f42bebd1f455391f41f 100644 (file)
--- a/ast.c
+++ b/ast.c
@@ -621,6 +621,8 @@ bool ast_block_set_type(ast_block *self, ast_expression *from)
         if (!self->expression.next)
             return false;
     }
+    else
+        self->expression.next = NULL;
     return true;
 }