From 0d9efb959673c3867e5f916793c83d3f08a2cf22 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Tue, 23 Jan 2018 09:28:27 -0800 Subject: On Windows, we have our own ether_ntohost(); declare it. Move the source to our own ether_ntohost() to the "missing" directory, just as we do in libpcap for the Windows snprintf() wrapper around _snprintf(). Add a header file for it, and include it in both the wrapper and in addrtoname.c on Windows. --- addrtoname.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'addrtoname.c') diff --git a/addrtoname.c b/addrtoname.c index 03fd5a07..55937929 100644 --- a/addrtoname.c +++ b/addrtoname.c @@ -40,7 +40,13 @@ #define HTONS(x) (x) = htons(x) #endif -#ifndef _WIN32 +#ifdef _WIN32 + /* + * We have our own ether_ntohost(), reading from the system's + * Ethernet address file. + */ + #include "missing/win_ether_ntohost.h" +#else #ifdef USE_ETHER_NTOHOST #if defined(NET_ETHERNET_H_DECLARES_ETHER_NTOHOST) /* -- cgit v1.2.1