summaryrefslogtreecommitdiff
path: root/common/compat.h
diff options
context:
space:
mode:
Diffstat (limited to 'common/compat.h')
-rw-r--r--common/compat.h20
1 files changed, 10 insertions, 10 deletions
diff --git a/common/compat.h b/common/compat.h
index 5bcdfe2..48d97b3 100644
--- a/common/compat.h
+++ b/common/compat.h
@@ -115,14 +115,14 @@ int p11_thread_join (thread_t thread);
typedef HMODULE dl_module_t;
-#define p11_module_open(f) \
+#define p11_dl_open(f) \
(LoadLibrary (f))
-#define p11_module_close(d) \
+#define p11_dl_close(d) \
(FreeLibrary (d))
-#define p11_module_symbol(d, s) \
+#define p11_dl_symbol(d, s) \
((void *)GetProcAddress ((d), (s)))
-const char * p11_module_error (void);
+char * p11_dl_error (void);
#define p11_sleep_ms(ms) \
(Sleep (ms))
@@ -165,15 +165,15 @@ typedef void * (*p11_thread_routine) (void *arg);
typedef void * dl_module_t;
-#define p11_module_open(f) \
+#define p11_dl_open(f) \
(dlopen ((f), RTLD_LOCAL | RTLD_NOW))
-#define p11_module_close(d) \
- (dlclose(d))
-#define p11_module_error() \
- (dlerror ())
-#define p11_module_symbol(d, s) \
+#define p11_dl_close \
+ dlclose
+#define p11_dl_symbol(d, s) \
(dlsym ((d), (s)))
+char * p11_dl_error (void);
+
#define p11_sleep_ms(ms) \
do { int _ms = (ms); \
struct timespec _ts = { _ms / 1000, (_ms % 1000) * 1000 * 1000 }; \