]> git.ipfire.org Git - thirdparty/systemd.git/commit
network: dhcp6-pd: exclude all explicitly specified subnet IDs when searching free IDs
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 1 Dec 2021 10:43:40 +0000 (19:43 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 1 Dec 2021 11:35:03 +0000 (20:35 +0900)
commit1a4ca0e2f35d859f2d7f3bb8c94eefe2ad1c2ff4
tree3bdbf81e7b85b7fb5d0dfe3d8604bc34a882abfb
parenta74229c58ed4e472875829589502119e4badc483
network: dhcp6-pd: exclude all explicitly specified subnet IDs when searching free IDs

When the upstream link gained a lease, then several downstream links may
not appear yet. Previously, the explicitly specified subnet ID for a
downstream link which appears later may be already assigned to an
interface which does not request specific subnet ID.

To avoid such situation, this makes all specified IDs are excluded when
searching free IDs.

As a side effect, we can avoid the second call of
dhcp6_pd_distribute_prefix().
src/network/networkd-dhcp6.c
src/network/networkd-manager.c
src/network/networkd-manager.h
src/network/networkd-network.c
src/network/networkd-network.h