diff options
author | Guy Harris <guy@alum.mit.edu> | 2019-01-09 10:36:25 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2019-01-09 10:36:25 -0800 |
commit | dc2d895444587d758991abd9c2beb40ae467da92 (patch) | |
tree | 2e8b5e4139b280194206bbc17f3f6d1864fb0471 /sockutils.h | |
parent | 317569428602e3e426bf8e94cdb5143a33c0c88a (diff) |
Put the Windows-vs-non-Windows socket defines in <pcap/socket.h>.
Diffstat (limited to 'sockutils.h')
-rw-r--r-- | sockutils.h | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/sockutils.h b/sockutils.h index fc271bf9..654e174c 100644 --- a/sockutils.h +++ b/sockutils.h @@ -37,28 +37,9 @@ #pragma once #endif -#ifdef _WIN32 - /* Need windef.h for defines used in winsock2.h under MingW32 */ - #ifdef __MINGW32__ - #include <windef.h> - #endif - #include <winsock2.h> - #include <ws2tcpip.h> - - /* - * Winsock doesn't have this UN*X type; it's used in the UN*X - * sockets API. - * - * XXX - do we need to worry about UN*Xes so old that *they* - * don't have it, either? - */ - typedef int socklen_t; +#include "pcap/socket.h" - /* - * Winsock doesn't have this POSIX type; it's used for the - * tv_usec value of struct timeval. - */ - typedef long suseconds_t; +#ifdef _WIN32 #else /* UN*X */ #include <stdio.h> |