From b388f4805c3ce6e0b7ce7e5995c9305529db8e46 Mon Sep 17 00:00:00 2001 From: Kirill Radkin Date: Mon, 25 Sep 2023 13:10:20 +0300 Subject: [PATCH] OpenOCD memory leak in `hwthread_update_threads()` Update `os_free()` from `rtos/rtos.c:96` to fix memory leaks Change-Id: Id7b4c775291b735a0b4423151c2930afce6bf0bd Signed-off-by: Kirill Radkin Reviewed-on: https://review.openocd.org/c/openocd/+/7934 Reviewed-by: Tim Newsome Tested-by: jenkins Reviewed-by: Antonio Borneo Reviewed-by: Tomas Vanek --- src/rtos/rtos.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/rtos/rtos.c b/src/rtos/rtos.c index 136d93bf6..0df1182c0 100644 --- a/src/rtos/rtos.c +++ b/src/rtos/rtos.c @@ -78,6 +78,7 @@ static void os_free(struct target *target) return; free(target->rtos->symbols); + rtos_free_threadlist(target->rtos); free(target->rtos); target->rtos = NULL; } -- 2.11.4.GIT