From 9962a048634c590db23a00db1d01daada779844c Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 24 Jun 2005 19:02:51 +0000 Subject: * implement new source address check mechanisms * introduce new types AvahiIfIndex and AvahiProtocol to abstract underlying OS structures a bit * document string list, address and other stuff * implement qclass = ANY queries * don't make use of UTF8 collation as RFC mandates git-svn-id: file:///home/lennart/svn/public/avahi/trunk@144 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- avahi-core/iface.h | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'avahi-core/iface.h') diff --git a/avahi-core/iface.h b/avahi-core/iface.h index 1372e6f..486207e 100644 --- a/avahi-core/iface.h +++ b/avahi-core/iface.h @@ -64,7 +64,7 @@ struct AvahiHwInterface { AvahiInterfaceMonitor *monitor; gchar *name; - gint index; + AvahiIfIndex index; guint flags; guint mtu; @@ -82,7 +82,7 @@ struct AvahiInterface { AvahiInterfaceMonitor *monitor; AvahiHwInterface *hardware; - guchar protocol; + AvahiProtocol protocol; gboolean announcing; AvahiCache *cache; @@ -100,6 +100,7 @@ struct AvahiInterfaceAddress { guchar flags; guchar scope; + guchar prefix_len; AvahiAddress address; AvahiEntryGroup *entry_group; @@ -111,7 +112,7 @@ void avahi_interface_monitor_free(AvahiInterfaceMonitor *m); void avahi_interface_monitor_sync(AvahiInterfaceMonitor *m); -AvahiInterface* avahi_interface_monitor_get_interface(AvahiInterfaceMonitor *m, gint index, guchar protocol); +AvahiInterface* avahi_interface_monitor_get_interface(AvahiInterfaceMonitor *m, AvahiIfIndex index, AvahiProtocol protocol); AvahiHwInterface* avahi_interface_monitor_get_hw_interface(AvahiInterfaceMonitor *m, gint index); void avahi_interface_send_packet(AvahiInterface *i, AvahiDnsPacket *p); @@ -126,14 +127,17 @@ void avahi_dump_caches(AvahiInterfaceMonitor *m, FILE *f); gboolean avahi_interface_relevant(AvahiInterface *i); gboolean avahi_interface_address_relevant(AvahiInterfaceAddress *a); -gboolean avahi_interface_match(AvahiInterface *i, gint index, guchar protocol); +gboolean avahi_interface_match(AvahiInterface *i, AvahiIfIndex index, AvahiProtocol protocol); typedef void (*AvahiInterfaceMonitorWalkCallback)(AvahiInterfaceMonitor *m, AvahiInterface *i, gpointer userdata); -void avahi_interface_monitor_walk(AvahiInterfaceMonitor *m, gint index, guchar protocol, AvahiInterfaceMonitorWalkCallback callback, gpointer userdata); +void avahi_interface_monitor_walk(AvahiInterfaceMonitor *m, AvahiIfIndex index, AvahiProtocol protocol, AvahiInterfaceMonitorWalkCallback callback, gpointer userdata); void avahi_update_host_rrs(AvahiInterfaceMonitor *m, gboolean remove); gboolean avahi_address_is_local(AvahiInterfaceMonitor *m, const AvahiAddress *a); +gboolean avahi_interface_address_on_link(AvahiInterface *i, const AvahiAddress *a); + + #endif -- cgit