Remove windows libraries from util.h and compat.h

This commit is contained in:
Nick Mathewson 2018-06-29 11:07:16 -04:00
parent 31897a256c
commit 71e56c70e9
5 changed files with 8 additions and 13 deletions

View File

@ -7,10 +7,6 @@
#define TOR_COMPAT_H
#include "orconfig.h"
#ifdef _WIN32
#include <winsock2.h>
#include <ws2tcpip.h>
#endif
#include "lib/cc/torint.h"
#include "lib/testsupport/testsupport.h"
#ifdef HAVE_SYS_PARAM_H
@ -48,7 +44,6 @@
#include "lib/string/compat_ctype.h"
#include "lib/string/compat_string.h"
#include "lib/string/printf.h"
#include "lib/log/win32err.h"
#include "lib/net/socket.h"
#include "lib/net/ipv4.h"
#include "lib/net/ipv6.h"

View File

@ -8,7 +8,11 @@
#include "common/procmon.h"
#include "common/util.h"
#include "lib/log/torlog.h"
#include "lib/log/util_bug.h"
#include "lib/log/win32err.h"
#include "lib/malloc/util_malloc.h"
#include "lib/string/parse_int.h"
#ifdef HAVE_SIGNAL_H
#include <signal.h>
@ -329,4 +333,3 @@ tor_process_monitor_free_(tor_process_monitor_t *procmon)
tor_free(procmon);
}

View File

@ -18,10 +18,6 @@
#include "lib/testsupport/testsupport.h"
#include <stdio.h>
#include <stdlib.h>
#ifdef _WIN32
/* for the correct alias to struct stat */
#include <sys/stat.h>
#endif
#include "lib/err/torerr.h"
#include "lib/malloc/util_malloc.h"
#include "lib/wallclock/approx_time.h"
@ -41,7 +37,6 @@
#include "lib/fs/path.h"
#include "lib/encoding/time_fmt.h"
#include "lib/encoding/cstring.h"
#include "lib/fs/winlib.h"
/* Math functions */

View File

@ -23,6 +23,8 @@
#include "or/config.h"
#include "or/main.h"
#include "or/ntmain.h"
#include "lib/log/win32err.h"
#include "lib/fs/winlib.h"
#include <windows.h>
#define GENSRV_SERVICENAME "tor"
@ -778,4 +780,3 @@ nt_service_parse_options(int argc, char **argv, int *should_exit)
}
#endif /* defined(_WIN32) */

View File

@ -25,6 +25,7 @@
#include "lib/compress/compress_zstd.h"
#include "lib/encoding/keyval.h"
#include "lib/fdio/fdio.h"
#include "lib/fs/winlib.h"
#include "lib/process/env.h"
#include "lib/process/pidfile.h"
#include "lib/process/subprocess.h"