From: Shane Lontis Date: Tue, 11 Aug 2020 05:24:52 +0000 (+1000) Subject: Fix coverity CID #1465794 - Uninitialized pointer read in x942_encode_otherinfo() X-Git-Tag: openssl-3.0.0-alpha7~508 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=61d61c5fd227903bb34562fc06531e91e9453f64;p=thirdparty%2Fopenssl.git Fix coverity CID #1465794 - Uninitialized pointer read in x942_encode_otherinfo() Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/12628) --- diff --git a/providers/implementations/kdfs/x942kdf.c b/providers/implementations/kdfs/x942kdf.c index 3ca87cddc2e..d1a1ee443c9 100644 --- a/providers/implementations/kdfs/x942kdf.c +++ b/providers/implementations/kdfs/x942kdf.c @@ -164,7 +164,7 @@ static int x942_encode_otherinfo(size_t keylen, /* keylenbits must fit into 4 bytes */ if (keylen > 0xFFFFFF) - goto err; + return 0; keylen_bits = 8 * keylen; /* Calculate the size of the buffer */