You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ti...@apache.org on 2019/09/19 13:22:42 UTC
[mesos] branch master updated: Windows: Moved definition out of
inline function call.
This is an automated email from the ASF dual-hosted git repository.
tillt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mesos.git
The following commit(s) were added to refs/heads/master by this push:
new fe1cd0a Windows: Moved definition out of inline function call.
fe1cd0a is described below
commit fe1cd0a3bb73ce39314e03a23e4d60f43bab6cf0
Author: Joseph Wu <jo...@mesosphere.io>
AuthorDate: Thu Sep 19 15:22:15 2019 +0200
Windows: Moved definition out of inline function call.
MSVC does not deal with #ifdefs from inside function calls.
So here, the `#if defined(...)` was taken literally and is
considered a syntax error by MSVC.
Review: https://reviews.apache.org/r/71478/
---
3rdparty/libprocess/src/openssl.cpp | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/3rdparty/libprocess/src/openssl.cpp b/3rdparty/libprocess/src/openssl.cpp
index 5854711..54d47cd 100644
--- a/3rdparty/libprocess/src/openssl.cpp
+++ b/3rdparty/libprocess/src/openssl.cpp
@@ -724,23 +724,23 @@ void reinitialize()
<< "(OpenSSL error #" << stringify(error) << "): " << error_string(error);
}
+ long ssl_options =
+ SSL_OP_NO_SSLv2 |
+ SSL_OP_NO_SSLv3 |
+ SSL_OP_NO_TLSv1 |
+ SSL_OP_NO_TLSv1_1 |
+#if defined(SSL_OP_NO_TLSv1_3)
+ SSL_OP_NO_TLSv1_3 |
+#endif
+ SSL_OP_NO_TLSv1_2;
+
// Clear all the protocol options. They will be reset if needed
// below. We do this because 'SSL_CTX_set_options' only augments, it
// does not do an overwrite.
- SSL_CTX_clear_options(
- ctx,
- SSL_OP_NO_SSLv2 |
- SSL_OP_NO_SSLv3 |
- SSL_OP_NO_TLSv1 |
- SSL_OP_NO_TLSv1_1 |
- SSL_OP_NO_TLSv1_2
-#if defined(SSL_OP_NO_TLSv1_3)
- | SSL_OP_NO_TLSv1_3
-#endif
- );
+ SSL_CTX_clear_options(ctx, ssl_options);
// Use server preference for cipher.
- long ssl_options = SSL_OP_CIPHER_SERVER_PREFERENCE;
+ ssl_options = SSL_OP_CIPHER_SERVER_PREFERENCE;
// Always disable SSLv2. We do this because most systems have
// disabled SSLv2 at compilation due to having so many security