diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-08-31 14:43:15 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-08-31 14:43:15 -0700 |
commit | f79d3e15d171a19565a0a106f24540d5f7ae5d93 (patch) | |
tree | 92be7b7a38f0d6e690ac4f08d2783af1efa191d4 /addrtoname.c | |
parent | 668e3cf744f2397c8ed7f234f1dc3b13b31eebdf (diff) | |
download | tcpdump-f79d3e15d171a19565a0a106f24540d5f7ae5d93.tar.gz |
The official #define for 32-bit and 64-bit Windows is _WIN32.
It's _WIN32, with a leading underscore, not WIN32. See, for example:
https://sourceforge.net/p/predef/wiki/OperatingSystems/
and
https://msdn.microsoft.com/en-us/library/b0084kay.aspx
*Some* environments may also define WIN32, but we shouldn't depend on
that.
Diffstat (limited to 'addrtoname.c')
-rw-r--r-- | addrtoname.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/addrtoname.c b/addrtoname.c index f772801a..551ebb90 100644 --- a/addrtoname.c +++ b/addrtoname.c @@ -89,7 +89,7 @@ static struct hnamemem eprototable[HASHNAMESIZE]; static struct hnamemem dnaddrtable[HASHNAMESIZE]; static struct hnamemem ipxsaptable[HASHNAMESIZE]; -#if defined(INET6) && defined(WIN32) +#if defined(INET6) && defined(_WIN32) /* * fake gethostbyaddr for Win2k/XP * gethostbyaddr() returns incorrect value when AF_INET6 is passed @@ -127,7 +127,7 @@ win32_gethostbyaddr(const char *addr, int len, int type) } } #define gethostbyaddr win32_gethostbyaddr -#endif /* INET6 & WIN32 */ +#endif /* INET6 & _WIN32 */ #ifdef INET6 struct h6namemem { @@ -775,7 +775,7 @@ init_servarray(netdissect_options *ndo) } /* in libpcap.a (nametoaddr.c) */ -#if defined(WIN32) && !defined(USE_STATIC_LIBPCAP) +#if defined(_WIN32) && !defined(USE_STATIC_LIBPCAP) extern __declspec(dllimport) #else extern |