Commit 2a99aa0f authored by Philipp Schafft's avatar Philipp Schafft 🦁

Fix: memory leak, now also releasing reglist[] members

parent 87029992
......@@ -36,12 +36,17 @@ static void event_addref(event_t *event) {
}
static void event_release(event_t *event) {
size_t i;
if (!event)
return;
event->refcount--;
if (event->refcount)
return;
for (i = 0; i < (sizeof(event->reglist)/sizeof(*event->reglist)); i++)
event_registration_release(event->reglist[i]);
free(event->trigger);
free(event->uri);
free(event->connection_ip);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment