ifaddrs: add extern "C"

We need this to be callable from C programs. Thanks to Diver for
reporting!
This commit is contained in:
Adrien Destugues
2015-02-26 22:02:37 +01:00
parent 85e5aa30b1
commit e3468ef600
+10
View File
@@ -6,6 +6,11 @@
#define _IFADDRS_H
#ifdef __cplusplus
extern "C" {
#endif
struct ifaddrs {
struct ifaddrs *ifa_next; /* Next item in list */
const char *ifa_name; /* Name of interface */
@@ -22,4 +27,9 @@ int getifaddrs(struct ifaddrs **ifap);
void freeifaddrs(struct ifaddrs *ifa);
#ifdef __cplusplus
}
#endif
#endif