applications/luci-upnp: add a note that up and download speeds are informational...
[project/luci.git] / contrib / fwd / src / fwd_addr.h
index 1a28f64..3cabe09 100644 (file)
 #include <arpa/inet.h>
 
 
-struct fwd_addr_list {
+struct fwd_addr {
        char ifname[IFNAMSIZ];
        char label[IFNAMSIZ];
        int family;
        int index;
-       unsigned int prefix;
-       union {
-               struct in_addr v4;
-               struct in6_addr v6;
-       } ipaddr;
-       struct fwd_addr_list *next;
+       struct fwd_cidr ipaddr;
+       struct fwd_addr *next;
 };
 
 
-struct fwd_addr_list * fwd_get_addrs(int, int);
-struct fwd_addr_list * fwd_append_addrs(struct fwd_addr_list *, struct fwd_addr_list *);
-void fwd_free_addrs(struct fwd_addr_list *);
+struct fwd_addr * fwd_get_addrs(int, int);
+struct fwd_addr * fwd_append_addrs(struct fwd_addr *, struct fwd_addr *);
+void fwd_free_addrs(struct fwd_addr *);
+
+struct fwd_cidr * fwd_lookup_addr(struct fwd_addr *, const char *);
 
 #define fwd_foreach_addrs(head, entry) for(entry = head; entry; entry = entry->next)