add: schedule tags endpoint

fix: memory leak for string args
This commit is contained in:
Tobias Reisinger 2020-05-06 10:53:42 +02:00
parent a127a68e31
commit f040cd8b21
6 changed files with 71 additions and 2 deletions
handlers

View file

@ -16,6 +16,14 @@ handler_connection(struct mg_connection *c, int ev, void *p)
if(endpoint && endpoint->func)
{
endpoint->func(c, endpoint->args, p);
for(int i = 0; i < endpoint->args_count; ++i)
{
if(endpoint->args[i].type == ENDPOINT_ARG_TYPE_STR)
{
free((char*)endpoint->args[i].value.v_str);
}
}
}
else
{