Commit 31cf68b0 authored by Juliusz Chroboczek's avatar Juliusz Chroboczek

Use FOR_ALL_NETS in kernel_netlink.c.

parent 6802457e
......@@ -1028,7 +1028,7 @@ filter_link(struct nlmsghdr *nh, void *data)
int ifindex;
char *ifname;
unsigned int ifflags;
int i;
struct network *net;
len = nh->nlmsg_len;
......@@ -1046,10 +1046,9 @@ filter_link(struct nlmsghdr *nh, void *data)
return 0;
kdebugf("filter_interfaces: link change on if %s(%d): %s\n",
ifname, ifindex, parse_ifflags(ifflags));
for (i = 0; i < numnets; i++) {
if (!strcmp(nets[i].ifname, ifname)) {
FOR_ALL_NETS(net) {
if (strcmp(net->ifname, ifname) == 0)
return 1;
}
}
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment