On 25/08/15 17:31, Simon Wunderlich wrote:
batadv_orig_node_vlan_get() returns NULL if we don't know this VLAN for that Originator, therefore the CRC check fails here.
That's right, however it only sweeps through the VLANs announced within the TT-TVLV. However, my addition tries to check if there are any excess VLAN locally which are NOT in that TT-TVLV. I think this patch doesn't take care of that, or am I missing something?
For example, think of having VLAN 6 locally with a couple of global entries at the originator, but the TT-TVLV only announces VLANs 3,4,5. Then the fact that we also have VLAN 6 is not detected, and these (probably wrong) entries are never cleaned up.
Right, this check is required, but what about just checking the VLAN count in the tt packet and in the originator struct ? if the number is different it means that there must be an excess in the local struct.
Cheers,