summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>2001-08-03 10:44:51 +0200
committerMartin Mares <mj@ucw.cz>2001-08-03 10:44:51 +0200
commit5fc7c5c51344a8cc1fae2cc9077c2c331c1e419a (patch)
tree321e809383563b3f2748be87560865ac7fe64da3
parent24c00cb11915edb8c13dbc21f245a73fc34689ed (diff)
downloadbird-5fc7c5c51344a8cc1fae2cc9077c2c331c1e419a.tar
bird-5fc7c5c51344a8cc1fae2cc9077c2c331c1e419a.zip
Don't loop forever when trying to skip an out-sequence netlink reply.
-rw-r--r--sysdep/linux/netlink/netlink.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdep/linux/netlink/netlink.c b/sysdep/linux/netlink/netlink.c
index fd9b371..d08a121 100644
--- a/sysdep/linux/netlink/netlink.c
+++ b/sysdep/linux/netlink/netlink.c
@@ -114,13 +114,13 @@ nl_get_reply(void)
if (NLMSG_OK(nl_last_hdr, nl_last_size))
{
struct nlmsghdr *h = nl_last_hdr;
+ nl_last_hdr = NLMSG_NEXT(h, nl_last_size);
if (h->nlmsg_seq != nl_sync_seq)
{
log(L_WARN "nl_get_reply: Ignoring out of sequence netlink packet (%x != %x)",
h->nlmsg_seq, nl_sync_seq);
continue;
}
- nl_last_hdr = NLMSG_NEXT(h, nl_last_size);
return h;
}
if (nl_last_size)