diff options
| author | Tobias Markmann <tobias.markmann@isode.com> | 2019-09-17 08:28:22 (GMT) |
|---|---|---|
| committer | Tobias Markmann <tobias.markmann@isode.com> | 2019-09-17 08:28:22 (GMT) |
| commit | f15902a76e0f3ff0151fb34dcfae2db75a2f5fb7 (patch) | |
| tree | 310fa04594575bfaff1eafe36227acf27aec0fe1 /Swiften/TLS/OpenSSL | |
| parent | 181ac4a83ba4a82be683fb0a6f08393d3c91320c (diff) | |
| download | swift-f15902a76e0f3ff0151fb34dcfae2db75a2f5fb7.zip swift-f15902a76e0f3ff0151fb34dcfae2db75a2f5fb7.tar.bz2 | |
Fix casing of enums to avoid conflict on Windows
Test-Information:
Tested on Windows with OpenSSL that this fixes the
compilation issue.
Change-Id: I01887c8eb758a6c1c208244cdae32aa9c0a99565
Diffstat (limited to 'Swiften/TLS/OpenSSL')
| -rw-r--r-- | Swiften/TLS/OpenSSL/OpenSSLContext.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Swiften/TLS/OpenSSL/OpenSSLContext.cpp b/Swiften/TLS/OpenSSL/OpenSSLContext.cpp index e585766..5c80976 100644 --- a/Swiften/TLS/OpenSSL/OpenSSLContext.cpp +++ b/Swiften/TLS/OpenSSL/OpenSSLContext.cpp @@ -329,25 +329,25 @@ bool OpenSSLContext::configure(const TLSOptions &options) verifyCertCallback = *options.verifyCertificateCallback; } else { verifyCertCallback = nullptr; } if (options.verifyMode) { TLSOptions::VerifyMode verify_mode = *options.verifyMode; int mode; switch (verify_mode) { - case TLSOptions::VerifyMode::NONE: + case TLSOptions::VerifyMode::None: mode = SSL_VERIFY_NONE; break; - case TLSOptions::VerifyMode::REQUIRED: + case TLSOptions::VerifyMode::Required: mode = SSL_VERIFY_PEER | SSL_VERIFY_FAIL_IF_NO_PEER_CERT | SSL_VERIFY_CLIENT_ONCE; break; - case TLSOptions::VerifyMode::OPTIONAL: + case TLSOptions::VerifyMode::Optional: mode = SSL_VERIFY_PEER | SSL_VERIFY_CLIENT_ONCE; break; } // Set up default certificate chain verification depth - may be overridden below SSL_CTX_set_verify_depth(context_.get(), SSL_DEFAULT_VERIFY_DEPTH + 1); // Set callbacks up SSL_CTX_set_verify(context_.get(), mode, verifyCallback); |
Swift