From: Colin Whittaker Date: Sat, 24 Jun 2023 20:33:12 +0000 (-0700) Subject: config: make sure timer is not on the timeouts list before freeing X-Git-Url: http://git.openwrt.org//?a=commitdiff_plain;h=d8118f6e76e5519881f9a37137c3a06b3cb60fd2;p=project%2Fodhcpd.git config: make sure timer is not on the timeouts list before freeing Signed-off-by: Colin Whittaker Signed-off-by: Chad Monroe --- diff --git a/src/config.c b/src/config.c index 5ba4d9e..1cd4608 100644 --- a/src/config.c +++ b/src/config.c @@ -259,6 +259,9 @@ static void close_interface(struct interface *iface) dhcpv4_setup_interface(iface, false); #endif + /* make sure timer is not on the timeouts list before freeing */ + uloop_timeout_cancel(&iface->timer_rs); + clean_interface(iface); free(iface->addr4); free(iface->addr6);