mem leak in lex for flex 2.6

This commit is contained in:
Olof hagsand 2017-04-07 10:59:30 +02:00
parent 31c45e5c62
commit 7880b5d498
4 changed files with 24 additions and 29 deletions

View file

@ -131,11 +131,7 @@ int
json_scan_exit(struct clicon_json_yacc_arg *jy)
{
yy_delete_buffer(jy->jy_lexbuf);
#if defined(YY_FLEX_SUBMINOR_VERSION) && YY_FLEX_SUBMINOR_VERSION >= 9
clixon_json_parselex_destroy(); /* modern */
#else
yy_init = 1; /* This does not quite free all buffers */
#endif
return 0;
}