[mod_verto] Fix memory leak by correctly freeing regex
For mod_verto regex was never freed and was actually leaking memory. Correctly free the compiled regex to fix the memory leak. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
This commit is contained in:
parent
ee7c7dea60
commit
83b38714b9
|
@ -1893,10 +1893,12 @@ authed:
|
|||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG,
|
||||
"%d request [%s] matched expr [%s]\n", proceed, request->uri, expression);
|
||||
request->uri = rule->value;
|
||||
switch_regex_safe_free(re);
|
||||
break;
|
||||
}
|
||||
|
||||
rule = rule->next;
|
||||
switch_regex_safe_free(re);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue