summaryrefslogtreecommitdiff
path: root/hw/xfree86/parser/Video.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/xfree86/parser/Video.c')
-rw-r--r--hw/xfree86/parser/Video.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/xfree86/parser/Video.c b/hw/xfree86/parser/Video.c
index 4e8526f3f..108c8f3ad 100644
--- a/hw/xfree86/parser/Video.c
+++ b/hw/xfree86/parser/Video.c
@@ -97,6 +97,8 @@ xf86parseVideoPortSubSection(void)
switch (token) {
case COMMENT:
ptr->vp_comment = xf86addComment(ptr->vp_comment, xf86_lex_val.str);
+ free(xf86_lex_val.str);
+ xf86_lex_val.str = NULL;
break;
case IDENTIFIER:
if (xf86getSubToken(&(ptr->vp_comment)) != STRING)
@@ -154,6 +156,8 @@ xf86parseVideoAdaptorSection(void)
switch (token) {
case COMMENT:
ptr->va_comment = xf86addComment(ptr->va_comment, xf86_lex_val.str);
+ free(xf86_lex_val.str);
+ xf86_lex_val.str = NULL;
break;
case IDENTIFIER:
if (xf86getSubToken(&(ptr->va_comment)) != STRING)