git: wg: Fix callout leak by adding callout_terminate()
Aaron LI
aly at crater.dragonflybsd.org
Sun Mar 16 22:08:09 PDT 2025
commit 5d3c69bcb5a873251833a87dd1f1be79534f3406
Author: Aaron LI <aly at aaronly.me>
Date: Mon Mar 17 12:58:49 2025 +0800
wg: Fix callout leak by adding callout_terminate()
DragonFly allocates an internal '_callout' struct for a 'callout' struct,
so the callout_terminate() function must be called to free the internal
struct before releasing a 'callout' struct.
On the contrary, FreeBSD fully embeds the info into a 'callout' struct
and does not need (and actually does not have) the callout_terminate().
Summary of changes:
sys/net/wg/if_wg.c | 6 ++++++
sys/net/wg/wg_cookie.c | 1 +
2 files changed, 7 insertions(+)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/5d3c69bcb5a873251833a87dd1f1be79534f3406
--
DragonFly BSD source repository
More information about the Commits
mailing list