From ded3735ef4d4e04efbef4fd78db22f2a5f129e10 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Mon, 9 Dec 2019 13:20:04 +0100 Subject: [PATCH] kill: deallocate follow_ups [assan] Signed-off-by: Karel Zak --- misc-utils/kill.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/misc-utils/kill.c b/misc-utils/kill.c index cf4e71154..91cc14c9a 100644 --- a/misc-utils/kill.c +++ b/misc-utils/kill.c @@ -494,6 +494,12 @@ int main(int argc, char **argv) } } + while (!list_empty(&ctl.follow_ups)) { + struct timeouts *x = list_entry(ctl.follow_ups.next, + struct timeouts, follow_ups); + list_del(&x->follow_ups); + free(x); + } if (ct && nerrs == 0) return EXIT_SUCCESS; /* full success */ else if (ct == nerrs)