]> git.rm.cloudns.org Git - xonotic/gmqcc.git/commitdiff
at last, the annoying missing ast_delete(typevar)
authorWolfgang (Blub) Bumiller <blub@speed.at>
Tue, 21 Aug 2012 09:21:05 +0000 (11:21 +0200)
committerWolfgang (Blub) Bumiller <blub@speed.at>
Tue, 21 Aug 2012 09:21:05 +0000 (11:21 +0200)
parser.c

index a3241c82e4eb2e72d42f40abc4ee59652b26fdd0..ea1e24d310008d4dd5d2cdd643e11a681a10dd75 100644 (file)
--- a/parser.c
+++ b/parser.c
@@ -2449,8 +2449,10 @@ nextvar:
                 return false;
             }
 
-            if (parser->tok == ';')
+            if (parser->tok == ';') {
+                ast_value_delete(typevar);
                 return parser_next(parser) || parser->tok == TOKEN_EOF;
+            }
             else if (opts_standard == COMPILER_QCC)
                 parseerror(parser, "missing semicolon after function body (mandatory with -std=qcc)");
             ast_value_delete(typevar);