From 07e2993b1fecdfe269c17ff2f07c99ce5c614fe8 Mon Sep 17 00:00:00 2001 From: Alexander Bluhm Date: Mon, 4 Dec 2023 14:38:17 +0100 Subject: [PATCH] Fix memory leak in error case when parsing table. --- parse.y | 1 + 1 file changed, 1 insertion(+) diff --git a/parse.y b/parse.y index 3d4d3b5..5f7df85 100644 --- a/parse.y +++ b/parse.y @@ -833,6 +833,7 @@ table_lookup_or_create(const char *table_name) if (strlcpy(table->pft_name, table_name, sizeof(table->pft_name)) >= sizeof(table->pft_name)) { yyerror("table name is too long"); + free(table); return (NULL); }