In case a netlink route event is received for a default route
netlink data attributes were faulty processed as neigbor netlink
data. Fix this by not processing any netlink attribute for
any route event.
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|| ndm->ndm_family != AF_INET6)
continue;
- // Inform about a change in default route
- if (is_route && rtm->rtm_dst_len == 0)
- raise(SIGUSR1);
- else if (is_route)
+ if (is_route) {
+ // Inform about a change in default route
+ if (rtm->rtm_dst_len == 0)
+ raise(SIGUSR1);
+
continue;
+ }
// Data to retrieve
size_t rta_offset = (is_addr) ? sizeof(struct ifaddrmsg) : sizeof(*ndm);