]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Fix segfault on qlog creation with no tls
authorNeil Horman <nhorman@openssl.org>
Thu, 17 Apr 2025 15:51:07 +0000 (11:51 -0400)
committerNeil Horman <nhorman@openssl.org>
Fri, 5 Dec 2025 15:13:26 +0000 (10:13 -0500)
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/27397)

ssl/quic/quic_port.c

index 6f2be905721e322f3ca294a72b02faf1ae1ebf9a..326a0ab0982b9bd344a3039d8776370a4596a97a 100644 (file)
@@ -554,7 +554,7 @@ static QUIC_CHANNEL *port_make_channel(QUIC_PORT *port, SSL *tls, OSSL_QRX *qrx,
      * If we're using qlog, make sure the tls get further configured properly
      */
     ch->use_qlog = 1;
-    if (ch->tls->ctx->qlog_title != NULL) {
+    if (ch->tls && ch->tls->ctx->qlog_title != NULL) {
         if ((ch->qlog_title = OPENSSL_strdup(ch->tls->ctx->qlog_title)) == NULL) {
             OPENSSL_free(ch);
             return NULL;