From: Pauli Date: Wed, 16 Mar 2022 03:21:01 +0000 (+1100) Subject: Fix Coverity 1498611 & 1498608: uninitialised read X-Git-Tag: openssl-3.0.3~77 X-Git-Url: https://git.openssl.org/?p=openssl.git;a=commitdiff_plain;h=9d24e7bae79668ba60af9458f9db74a3493f3655 Fix Coverity 1498611 & 1498608: uninitialised read Reviewed-by: Shane Lontis Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/17893) (cherry picked from commit 09134f183f76539aa1294adfef10fcc694e90267) --- diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 96a5822f30..28304a700d 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -2232,6 +2232,7 @@ int SSL_shutdown(SSL *s) if ((s->mode & SSL_MODE_ASYNC) && ASYNC_get_current_job() == NULL) { struct ssl_async_args args; + memset(&args, 0, sizeof(args)); args.s = s; args.type = OTHERFUNC; args.f.func_other = s->method->ssl_shutdown; @@ -3914,6 +3915,7 @@ int SSL_do_handshake(SSL *s) if ((s->mode & SSL_MODE_ASYNC) && ASYNC_get_current_job() == NULL) { struct ssl_async_args args; + memset(&args, 0, sizeof(args)); args.s = s; ret = ssl_start_async_job(s, &args, ssl_do_handshake_intern);