import of dnsmasq-2.36.tar.gz
diff --git a/src/netlink.c b/src/netlink.c
index 1be6c9a..b744ac9 100644
--- a/src/netlink.c
+++ b/src/netlink.c
@@ -18,6 +18,14 @@
 #include <linux/netlink.h>
 #include <linux/rtnetlink.h>
 
+/* linux 2.6.19 buggers up the headers, patch it up here. */ 
+#ifndef IFA_RTA
+#  define IFA_RTA(r)  \
+       ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct ifaddrmsg))))
+
+#  include <linux/if_addr.h>
+#endif
+
 static struct iovec iov;
 
 static void nl_err(struct nlmsghdr *h);