summaryrefslogtreecommitdiffstats
path: root/engines/e_dasync.c
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2016-06-26 13:40:15 +0200
committerAndy Polyakov <appro@openssl.org>2016-07-08 11:49:44 +0200
commitf1f5ee17b64397eecfde39960ca11e94064297bd (patch)
tree811a0a155a461065aecca798e7b7e090de7b80d9 /engines/e_dasync.c
parentab6a591caa561017f881ed36028177f9582a74c6 (diff)
include/openssl: don't include <windows.h> in public headers.
If application uses any of Windows-specific interfaces, make it application developer's respondibility to include <windows.h>. Rationale is that <windows.h> is quite "toxic" and is sensitive to inclusion order (most notably in relation to <winsock2.h>). It's only natural to give complete control to the application developer. Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org>
Diffstat (limited to 'engines/e_dasync.c')
-rw-r--r--engines/e_dasync.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/engines/e_dasync.c b/engines/e_dasync.c
index ed3f00adb6..89b12775b1 100644
--- a/engines/e_dasync.c
+++ b/engines/e_dasync.c
@@ -7,6 +7,10 @@
* https://www.openssl.org/source/license.html
*/
+#if defined(_WIN32)
+# include <windows.h>
+#endif
+
#include <stdio.h>
#include <string.h>
@@ -28,7 +32,6 @@
#elif defined(_WIN32)
# undef ASYNC_WIN
# define ASYNC_WIN
-# include <windows.h>
#endif
#define DASYNC_LIB_NAME "DASYNC"