ufd.fd = rth.fd;
ufd.cb = bridge_event_cb;
uloop_fd_add(&ufd, ULOOP_READ | ULOOP_EDGE_TRIGGER);
+ bridge_event_cb(&ufd, 0);
return 0;
}
if (msg.msg_namelen != sizeof(nladdr)) {
ERROR("Sender address length == %d\n",
msg.msg_namelen);
- return -1;
+ continue;
}
for (h = (struct nlmsghdr *)buf; status >= sizeof(*h);) {
int err;
if (l < 0 || len > status) {
if (msg.msg_flags & MSG_TRUNC) {
ERROR("Truncated message\n");
- return -1;
+ continue;
}
ERROR(
"!!!malformed message: len=%d\n", len);
- return -1;
+ continue;
}
err = handler(&nladdr, h, jarg);
if (err < 0) {
ERROR("Handler returned %d\n", err);
- return err;
+ continue;
}
status -= NLMSG_ALIGN(len);
}
if (status) {
ERROR("!!!Remnant of size %d\n", status);
- return -1;
+ continue;
}
}
}