network,ndisc: use ndisc_captive_portal_free() at one more place

Fixes another memleak introduced by 64de00c49f.
Fixes #28283.
This commit is contained in:
Yu Watanabe 2023-07-07 06:18:36 +09:00
parent 19731f4a7b
commit 75a9122678

View file

@ -1004,7 +1004,7 @@ static int ndisc_drop_outdated(Link *link, usec_t timestamp_usec) {
if (cp->lifetime_usec >= timestamp_usec)
continue; /* the captive portal is still valid */
free(set_remove(link->ndisc_captive_portals, cp));
ndisc_captive_portal_free(set_remove(link->ndisc_captive_portals, cp));
updated = true;
}