File dhcp-4.1.1-in6_pktinfo-prototype.diff of Package dhcp.import4313

diff --git a/common/socket.c b/common/socket.c
index 036f7ae..6f56740 100644
--- a/common/socket.c
+++ b/common/socket.c
@@ -40,11 +40,16 @@
  * I have implemented it under Linux; other systems should be doable also.
  */
 
+#ifndef _GNU_SOURCE
+#define _GNU_SOURCE
+#endif
 #include "dhcpd.h"
 #include <errno.h>
 #include <sys/ioctl.h>
 #include <sys/uio.h>
 #include <sys/uio.h>
+#include <netinet/in.h> /* for struct in6_pktinfo, with glibc >= 2.10.1
+                           _GNU_SOURCE required to enable it */
 
 #ifdef USE_SOCKET_FALLBACK
 # if !defined (USE_SOCKET_SEND)
openSUSE Build Service is sponsored by