summaryrefslogtreecommitdiffstats
path: root/hcid/parser.y
diff options
context:
space:
mode:
Diffstat (limited to 'hcid/parser.y')
-rw-r--r--hcid/parser.y12
1 files changed, 8 insertions, 4 deletions
diff --git a/hcid/parser.y b/hcid/parser.y
index aae915e9..cf947fbf 100644
--- a/hcid/parser.y
+++ b/hcid/parser.y
@@ -50,6 +50,8 @@ int yyparse(void);
int yylex(void);
int yyerror(char *s);
+void yylex_destroy(void);
+
%}
%union {
@@ -221,23 +223,23 @@ device_opt:
dev_name:
WORD {
- $$ = strdup($1);
+ $$ = $1;
}
| STRING {
- $$ = strdup($1);
+ $$ = $1;
}
;
hci:
HCI {
- $$ = strdup($1);
+ $$ = $1;
}
;
bdaddr:
BDADDR {
- $$ = strdup($1);
+ $$ = $1;
}
;
@@ -329,5 +331,7 @@ int read_config(char *file)
fclose(yyin);
+ yylex_destroy();
+
return 0;
}