]> git.ipfire.org Git - thirdparty/systemd.git/commit
network: free DHCP client and friends in link_free() 35004/head
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 2 Nov 2024 20:07:55 +0000 (05:07 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 3 Nov 2024 00:14:36 +0000 (09:14 +0900)
commit49e501343274ed110f6927108794d135a1710480
treed157bb1edd2659bd5470d93dd28cc52e6926eb74
parentef45f5c8d0bfbeda2a57b28bba9831f044b23b21
network: free DHCP client and friends in link_free()

No functional change, at least now. Preparation for later commits.

But we are planning to extend KeepConfiguration= and also keep
addresses and so on assigned by other dynamic configuration protocol
like DHCPv6 or NDisc.
However, when link_free_engines() is called here, acquired addresses so
on by NDisc will be removed, even if link_stop_engines() handles
restarting networkd or KeepConfiguration= gracefully.
So, let's not free engines here, but free them later in link_free().
It is not necessary to be called here anyway.
src/network/networkd-link.c
src/network/networkd-link.h
src/network/networkd-manager.c