]> xenbits.xensource.com Git - unikraft/libs/lwip.git/commitdiff
lwip: Add compile guard for struct ifconf
authorSharan Santhanam <sharan.santhanam@neclab.eu>
Sun, 2 Feb 2020 13:39:11 +0000 (14:39 +0100)
committerSimon Kuenzer <simon.kuenzer@neclab.eu>
Thu, 6 Feb 2020 10:37:51 +0000 (11:37 +0100)
Fix to disable redefinition of struct ifconf from python

Signed-off-by: Sharan Santhanam <sharan.santhanam@neclab.eu>
Reviewed-by: Alexander Jung <a.jung@lancs.ac.uk>
include/net/if.h

index 1eb11d81b3908230964d0ca0ac8f7bd1d1ee728e..4eadc6d6557a8fca0bc2108fd17d7e03ff03a33c 100644 (file)
@@ -26,6 +26,7 @@ char *if_indextoname (unsigned int, char *);
 #define IFF_VOLATILE (IFF_LOOPBACK|IFF_POINTOPOINT|IFF_BROADCAST| \
         IFF_ECHO|IFF_MASTER|IFF_SLAVE|IFF_RUNNING|IFF_LOWER_UP|IFF_DORMANT)
 
+#if defined(_BSD_SOURCE)
 struct ifconf {
        int ifc_len;
        union {
@@ -33,6 +34,7 @@ struct ifconf {
                struct ifreq *ifcu_req;
        } ifc_ifcu;
 };
+#endif /* _BSD_SOURCE */
 #define ifc_buf         ifc_ifcu.ifcu_buf
 #define ifc_req         ifc_ifcu.ifcu_req