From: icy17 <1061499390@qq.com> Date: Wed, 7 Aug 2024 09:07:09 +0000 (+0800) Subject: Fix Potential NULL pointer dereference X-Git-Tag: openssl-3.4.0-alpha1~220 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18d491a6820e240a4ed4224c764a7c93b526e45f;p=thirdparty%2Fopenssl.git Fix Potential NULL pointer dereference CLA: trivial Reviewed-by: Paul Dale Reviewed-by: Paul Yang Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/25065) --- diff --git a/test/sslapitest.c b/test/sslapitest.c index fdb5ef49f8a..612e1aab009 100644 --- a/test/sslapitest.c +++ b/test/sslapitest.c @@ -1911,6 +1911,8 @@ static int test_tlsext_status_type(void) /* First just do various checks getting and setting tlsext_status_type */ clientssl = SSL_new(cctx); + if (!TEST_ptr(clientssl)) + goto end; if (!TEST_int_eq(SSL_get_tlsext_status_type(clientssl), -1) || !TEST_true(SSL_set_tlsext_status_type(clientssl, TLSEXT_STATUSTYPE_ocsp)) @@ -1926,6 +1928,8 @@ static int test_tlsext_status_type(void) goto end; clientssl = SSL_new(cctx); + if (!TEST_ptr(clientssl)) + goto end; if (SSL_get_tlsext_status_type(clientssl) != TLSEXT_STATUSTYPE_ocsp) goto end; SSL_free(clientssl);