From 91eb57574c70d6c438c3b06161a48548a772df5e Mon Sep 17 00:00:00 2001 From: Henrik Holst Date: Wed, 3 May 2023 22:17:25 +0200 Subject: [PATCH] fixed double free on exit from non use if cpu core parking/pinning was disabled by the logic then there would be a double free at exit --- daemon/gamemode-cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daemon/gamemode-cpu.c b/daemon/gamemode-cpu.c index 1ec5eb0..b6e26f6 100644 --- a/daemon/gamemode-cpu.c +++ b/daemon/gamemode-cpu.c @@ -433,7 +433,7 @@ void game_mode_apply_core_pinning(const GameModeCPUInfo *info, const pid_t clien void game_mode_free_cpu(GameModeCPUInfo **info) { - if (!(*info)) { + if ((*info)) { CPU_FREE((*info)->online); (*info)->online = NULL;