]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Fix coverity CID #1465794 - Uninitialized pointer read in x942_encode_otherinfo()
authorShane Lontis <shane.lontis@oracle.com>
Tue, 11 Aug 2020 05:24:52 +0000 (15:24 +1000)
committerShane Lontis <shane.lontis@oracle.com>
Mon, 24 Aug 2020 01:19:28 +0000 (11:19 +1000)
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/12628)

providers/implementations/kdfs/x942kdf.c

index 3ca87cddc2e1ebd8c6a773b7b64ce6dd83b56b6d..d1a1ee443c9c2eb0e9140a7506d5fddc7f81f181 100644 (file)
@@ -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 */