fix dangling pointer

This commit is contained in:
Richard de Boer 2025-05-31 13:45:16 +02:00
parent acc951e54a
commit 67dab322f9
No known key found for this signature in database

View file

@ -212,12 +212,10 @@ pcre *regexp_compile(struct session *ses, char *exp, int comp_option)
int check_one_regexp(struct session *ses, struct listnode *node, char *line, char *original, int comp_option)
{
char *exp, *str;
char *exp, *str, result[BUFFER_SIZE];
if (node->regex == NULL)
{
char result[BUFFER_SIZE];
substitute(ses, node->arg1, result, SUB_VAR|SUB_FUN);
exp = result;