]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
network,ndisc: use ndisc_captive_portal_free() at one more place
authorYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 6 Jul 2023 21:18:36 +0000 (06:18 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 7 Jul 2023 00:18:25 +0000 (09:18 +0900)
Fixes another memleak introduced by 64de00c49fde341d09b817164fe8cc8f7da46268.
Fixes #28283.

src/network/networkd-ndisc.c

index 765e68c263538b05dfaad241eb3a453d292a07bb..de7d3e6dfa71432153e6f1c3b77339d5f468f9ba 100644 (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;
         }