From 4ff69e4c9c3041a7b4d5a80091cd5e84fe556348 Mon Sep 17 00:00:00 2001 From: Todd Short Date: Fri, 5 Mar 2021 15:50:12 -0500 Subject: QUIC: Add compile/run-time checking for QUIC Different from 3.0.0 as there's no OpenSSL_info() --- crypto/cversion.c | 4 ++++ include/openssl/crypto.h | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/crypto/cversion.c b/crypto/cversion.c index 534e7eba55..cd7fa0c63e 100644 --- a/crypto/cversion.c +++ b/crypto/cversion.c @@ -38,6 +38,10 @@ const char *OpenSSL_version(int t) return "ENGINESDIR: \"" ENGINESDIR "\""; #else return "ENGINESDIR: N/A"; +#endif +#ifndef OPENSSL_NO_QUIC + case OPENSSL_INFO_QUIC: + return "QUIC"; #endif } return "not available"; diff --git a/include/openssl/crypto.h b/include/openssl/crypto.h index 7d0b526236..5fdd7c3d04 100644 --- a/include/openssl/crypto.h +++ b/include/openssl/crypto.h @@ -161,6 +161,10 @@ const char *OpenSSL_version(int type); # define OPENSSL_DIR 4 # define OPENSSL_ENGINES_DIR 5 +# ifndef OPENSSL_NO_QUIC +# define OPENSSL_INFO_QUIC 2000 +# endif + int OPENSSL_issetugid(void); typedef void CRYPTO_EX_new (void *parent, void *ptr, CRYPTO_EX_DATA *ad, -- 2.35.3