you guys missed one, or gcc gets ioctl magically
This commit is contained in:
parent
e6fca0b87d
commit
1d61e4c67d
@ -1,26 +1,28 @@
|
||||
$OpenBSD: patch-tests_framework_c,v 1.2 2017/06/20 07:18:19 ajacoutot Exp $
|
||||
$OpenBSD: patch-tests_framework_c,v 1.3 2017/06/21 11:28:06 espie Exp $
|
||||
|
||||
XXX needs SIOCGIFINDEX
|
||||
- Add missing headers.
|
||||
- Set interface index to -1 by default.
|
||||
|
||||
--- tests/framework.c.orig Thu May 12 21:11:43 2011
|
||||
+++ tests/framework.c Thu Sep 29 11:28:48 2011
|
||||
@@ -24,8 +24,12 @@
|
||||
Index: tests/framework.c
|
||||
--- tests/framework.c.orig
|
||||
+++ tests/framework.c
|
||||
@@ -24,8 +24,13 @@
|
||||
#include <avahi-client/client.h>
|
||||
#include <avahi-common/error.h>
|
||||
|
||||
-#include <net/if.h>
|
||||
+#include <sys/types.h>
|
||||
+#include <sys/socket.h>
|
||||
+#include <sys/sockio.h>
|
||||
#include <net/if.h>
|
||||
-#include <sys/ioctl.h>
|
||||
#include <sys/ioctl.h>
|
||||
+#include <net/if.h>
|
||||
+#include <net/if_dl.h>
|
||||
+#include <ifaddrs.h>
|
||||
|
||||
#include <errno.h>
|
||||
#include <unistd.h>
|
||||
@@ -188,12 +192,14 @@ epc_test_list_ifaces (void)
|
||||
@@ -188,12 +193,14 @@ epc_test_list_ifaces (void)
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -35,7 +37,7 @@ XXX needs SIOCGIFINDEX
|
||||
|
||||
/* The following allows to fall back to ifr_index on kFreeBSD, where
|
||||
ifr_ifindex does not exist. See bug #592474. */
|
||||
@@ -201,7 +207,7 @@ epc_test_list_ifaces (void)
|
||||
@@ -201,7 +208,7 @@ epc_test_list_ifaces (void)
|
||||
#define ifr_ifindex ifr_index
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user