From ae9510246cbd6ab525e2b0c865be938efe52dff5 Mon Sep 17 00:00:00 2001 From: Michael Ortmann <41313082+michaelortmann@users.noreply.github.com> Date: Mon, 10 Jun 2024 19:43:29 +0200 Subject: [PATCH] More --- src/tls.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/tls.c b/src/tls.c index 4a805e32a..9e594f008 100644 --- a/src/tls.c +++ b/src/tls.c @@ -603,6 +603,12 @@ static char *ssl_printnum(ASN1_INTEGER *i) char *data, *buf; BIO *bio = BIO_new(BIO_s_mem()); + if (!bio) { + debug0("TLS: ssl_printnum(): BIO_new(): error"); + buf = nmalloc(1); + *buf = 0; + return buf; + } i2a_ASN1_INTEGER(bio, i); len = BIO_get_mem_data(bio, &data); if (len > 0) {