X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=avahi-core%2Fiface-linux.c;h=910000da214be039871a9b85416d5f626da18ae7;hb=6014a9885431654d03484ae5ed0aded7268adfeb;hp=bc871524cb4d93971202610b21a70e51f6d995d3;hpb=ab758d7bf41d1d7565e80fe5d2bded0d18160ccb;p=catta diff --git a/avahi-core/iface-linux.c b/avahi-core/iface-linux.c index bc87152..910000d 100644 --- a/avahi-core/iface-linux.c +++ b/avahi-core/iface-linux.c @@ -98,7 +98,7 @@ static void netlink_callback(AvahiNetlink *nl, struct nlmsghdr *n, void* userdat (!m->server->config.use_iff_running || (ifinfomsg->ifi_flags & IFF_RUNNING)) && !(ifinfomsg->ifi_flags & IFF_LOOPBACK) && (ifinfomsg->ifi_flags & IFF_MULTICAST) && - !(ifinfomsg->ifi_flags & IFF_POINTOPOINT); + (m->server->config.allow_point_to_point || !(ifinfomsg->ifi_flags & IFF_POINTOPOINT)); /* Handle interface attributes */ l = NLMSG_PAYLOAD(n, sizeof(struct ifinfomsg)); @@ -124,8 +124,8 @@ static void netlink_callback(AvahiNetlink *nl, struct nlmsghdr *n, void* userdat /* Fill in hardware (MAC) address */ hw->mac_address_size = RTA_PAYLOAD(a); - if (hw->mac_address_size > AVAHI_MAX_MAC_ADDRESS) - hw->mac_address_size = AVAHI_MAX_MAC_ADDRESS; + if (hw->mac_address_size > AVAHI_MAC_ADDRESS_MAX) + hw->mac_address_size = AVAHI_MAC_ADDRESS_MAX; memcpy(hw->mac_address, RTA_DATA(a), hw->mac_address_size); break; @@ -352,10 +352,9 @@ void avahi_interface_monitor_sync(AvahiInterfaceMonitor *m) { /* Let's handle netlink events until we are done with wild * dumping */ - while (m->osdep.list != LIST_DONE) { + while (!m->list_complete) if (!avahi_netlink_work(m->osdep.netlink, 1) == 0) break; - } /* At this point Avahi knows about all local interfaces and * addresses in existance. */