summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sbin/unwind/parse.y4
-rw-r--r--usr.sbin/rad/parse.y4
2 files changed, 6 insertions, 2 deletions
diff --git a/sbin/unwind/parse.y b/sbin/unwind/parse.y
index 9c1a48bd3de..1c02f76c7ad 100644
--- a/sbin/unwind/parse.y
+++ b/sbin/unwind/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.9 2019/10/18 06:00:46 otto Exp $ */
+/* $OpenBSD: parse.y,v 1.10 2019/10/18 06:03:25 otto Exp $ */
/*
* Copyright (c) 2018 Florian Obser <florian@openbsd.org>
@@ -162,6 +162,8 @@ varset : STRING '=' string {
if (isspace((unsigned char)*s)) {
yyerror("macro name cannot contain "
"whitespace");
+ free($1);
+ free($3);
YYERROR;
}
}
diff --git a/usr.sbin/rad/parse.y b/usr.sbin/rad/parse.y
index 004e5e22f92..bb18c3d9c9c 100644
--- a/usr.sbin/rad/parse.y
+++ b/usr.sbin/rad/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.14 2019/05/10 01:29:31 guenther Exp $ */
+/* $OpenBSD: parse.y,v 1.15 2019/10/18 06:03:25 otto Exp $ */
/*
* Copyright (c) 2018 Florian Obser <florian@openbsd.org>
@@ -174,6 +174,8 @@ varset : STRING '=' string {
if (isspace((unsigned char)*s)) {
yyerror("macro name cannot contain "
"whitespace");
+ free($1);
+ free($3);
YYERROR;
}
}