From: Jaroslav Kysela Date: Tue, 16 May 2017 08:50:08 +0000 (+0200) Subject: idnode: fix the critical access-after-free in api_idnode_handler() X-Git-Tag: v4.2.2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=639744f569c9cc667a01a5f4d942bef09d9739b6;p=thirdparty%2Ftvheadend.git idnode: fix the critical access-after-free in api_idnode_handler() --- diff --git a/src/api/api_idnode.c b/src/api/api_idnode.c index 297069f3e..0890f902b 100644 --- a/src/api/api_idnode.c +++ b/src/api/api_idnode.c @@ -670,7 +670,8 @@ api_idnode_handler err = EPERM; } else { handler(perm, in); - idnode_perm_unset(in); + if (!destroyed) + idnode_perm_unset(in); } htsmsg_destroy(msg); }