]> git.ipfire.org Git - thirdparty/lldpd.git/commit
netlink: handle veth loops correctly
authorVincent Bernat <vincent@bernat.im>
Fri, 1 Jan 2016 20:11:02 +0000 (21:11 +0100)
committerVincent Bernat <vincent@bernat.im>
Fri, 1 Jan 2016 20:11:02 +0000 (21:11 +0100)
commit100266c1e2efa0857fbc1e681a765c753a5de3cf
tree258ada273b88dd21c078bdf8244a8f547a452d47
parentaafa99bd317693201e5384d22f58819770e4da4c
netlink: handle veth loops correctly

Since Linux 4.1, a pair of veth are referenced as IFLINK for each
other. We previously detected this loop easily and did break the loop by
removing this bogus information. However, when one of the interface is
updated, only the modified interface has IFLINK pointing to the other
interface. Therefore, no more loop but the information is incorrect. To
avoid that, don't reset indexes, just pointers. We only use indexes to
build correctly those pointers.
src/daemon/netlink.c