aboutsummaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-06-28 13:37:51 -0400
committerNick Mathewson <nickm@torproject.org>2018-06-28 13:37:51 -0400
commit02bb701bba5fb6b5eb6ce5716b8fff9fd2c5e028 (patch)
tree03b336e462f1f7d23db6aa89a1fbff9f754505ec /src/common
parent8fc15e4861b37f7799abde6b9d6ec63fdceb55da (diff)
downloadtor-02bb701bba5fb6b5eb6ce5716b8fff9fd2c5e028.tar.gz
tor-02bb701bba5fb6b5eb6ce5716b8fff9fd2c5e028.zip
Move DLL support to lib/fs
Diffstat (limited to 'src/common')
-rw-r--r--src/common/util.c15
-rw-r--r--src/common/util.h5
2 files changed, 1 insertions, 19 deletions
diff --git a/src/common/util.c b/src/common/util.c
index b31bb834e1..135af77c68 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -134,18 +134,3 @@ ENABLE_GCC_WARNING(aggregate-return)
/* =====
* Time
* ===== */
-
-#ifdef _WIN32
-HANDLE
-load_windows_system_library(const TCHAR *library_name)
-{
- TCHAR path[MAX_PATH];
- unsigned n;
- n = GetSystemDirectory(path, MAX_PATH);
- if (n == 0 || n + _tcslen(library_name) + 2 >= MAX_PATH)
- return 0;
- _tcscat(path, TEXT("\\"));
- _tcscat(path, library_name);
- return LoadLibrary(path);
-}
-#endif /* defined(_WIN32) */
diff --git a/src/common/util.h b/src/common/util.h
index f174cd3667..ffd958c42c 100644
--- a/src/common/util.h
+++ b/src/common/util.h
@@ -40,6 +40,7 @@
#include "lib/fs/path.h"
#include "lib/encoding/time_fmt.h"
#include "lib/encoding/cstring.h"
+#include "lib/fs/winlib.h"
void tor_log_mallinfo(int severity);
@@ -76,8 +77,4 @@ void tor_log_mallinfo(int severity);
((isSock) ? read_all_from_socket((fd), (buf), (count)) \
: read_all_from_fd((int)(fd), (buf), (count)))
-#ifdef _WIN32
-HANDLE load_windows_system_library(const TCHAR *library_name);
-#endif
-
#endif /* !defined(TOR_UTIL_H) */