From 4fa7eb98a06276841c35a3f3aa40f637747233ce Mon Sep 17 00:00:00 2001 From: ejurgensen Date: Thu, 2 Jan 2020 23:30:34 +0100 Subject: [PATCH] [daap/dacp] Fix for memleak when client hangs up --- src/httpd_daap.c | 1 + src/httpd_dacp.c | 1 + 2 files changed, 2 insertions(+) diff --git a/src/httpd_daap.c b/src/httpd_daap.c index 2ed41d61..17956b76 100644 --- a/src/httpd_daap.c +++ b/src/httpd_daap.c @@ -326,6 +326,7 @@ update_fail_cb(struct evhttp_connection *evcon, void *arg) if (evc) evhttp_connection_set_closecb(evc, NULL, NULL); + evhttp_request_free(ur->req); update_remove(ur); } diff --git a/src/httpd_dacp.c b/src/httpd_dacp.c index 59162a50..4d189905 100644 --- a/src/httpd_dacp.c +++ b/src/httpd_dacp.c @@ -840,6 +840,7 @@ update_fail_cb(struct evhttp_connection *evcon, void *arg) p->next = ur->next; } + evhttp_request_free(ur->req); free(ur); }