sd-netlink: always append new bridge FDB entries

This partially reverts 192a9d95ea (#19432).

Fixes #20305.
This commit is contained in:
Yu Watanabe
2021-08-04 18:16:47 +09:00
parent 42a45446bb
commit 74c1ab841f
+6 -2
View File
@@ -443,8 +443,12 @@ int sd_rtnl_message_new_neigh(sd_netlink *rtnl, sd_netlink_message **ret, uint16
if (r < 0)
return r;
if (nlmsg_type == RTM_NEWNEIGH)
(*ret)->hdr->nlmsg_flags |= NLM_F_CREATE | NLM_F_REPLACE;
if (nlmsg_type == RTM_NEWNEIGH) {
if (ndm_family == AF_BRIDGE)
(*ret)->hdr->nlmsg_flags |= NLM_F_CREATE | NLM_F_APPEND;
else
(*ret)->hdr->nlmsg_flags |= NLM_F_CREATE | NLM_F_REPLACE;
}
ndm = NLMSG_DATA((*ret)->hdr);