diff options
author | Hugo Landau <hlandau@openssl.org> | 2023-04-18 19:30:53 +0100 |
---|---|---|
committer | Hugo Landau <hlandau@openssl.org> | 2023-05-12 14:46:03 +0100 |
commit | 3e5a47d4de5754a2d2f42b3402bfe887010357ae (patch) | |
tree | ac8d28aa9b5574d4f08d439bc49b7e3cbc735add | |
parent | 072328dddb8371b865bd18caca9a77698e883c80 (diff) | |
download | openssl-new-3e5a47d4de5754a2d2f42b3402bfe887010357ae.tar.gz |
QUIC Dispatch: Add simple way to determine if SSL object is QUIC-related
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/20765)
-rw-r--r-- | ssl/quic/quic_local.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ssl/quic/quic_local.h b/ssl/quic/quic_local.h index fa5d8cee1e..a1e84e6854 100644 --- a/ssl/quic/quic_local.h +++ b/ssl/quic/quic_local.h @@ -179,10 +179,15 @@ void ossl_quic_conn_on_remote_conn_close(QUIC_CONNECTION *qc, : ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ ? (c SSL_CONNECTION *)((c QUIC_CONNECTION *)(ssl))->tls \ : NULL)) + +# define IS_QUIC(ssl) ((ssl) != NULL \ + && ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ + || (ssl)->type == SSL_TYPE_QUIC_XSO)) # else # define QUIC_CONNECTION_FROM_SSL_int(ssl, c) NULL # define QUIC_XSO_FROM_SSL_int(ssl, c) NULL # define SSL_CONNECTION_FROM_QUIC_SSL_int(ssl, c) NULL +# define IS_QUIC(ssl) 0 # endif # define QUIC_CONNECTION_FROM_SSL(ssl) \ |