]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
pem: fix coverity 1474426: uninitialised scalar variable.
authorPauli <ppzgs1@gmail.com>
Sun, 21 Mar 2021 23:49:10 +0000 (09:49 +1000)
committerPauli <ppzgs1@gmail.com>
Tue, 23 Mar 2021 23:12:43 +0000 (09:12 +1000)
Based on the value, it would with work properly or produce an error.  Most likely seems to have been the former.

Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14638)

crypto/pem/pvkfmt.c

index bc6f6fab71218298c0402ff0e69a34d49ba06417..432fd3461829245c54cfc63b62b2c2937ad7afaa 100644 (file)
@@ -323,7 +323,7 @@ EVP_PKEY *ossl_b2i_bio(BIO *in, int *ispub)
     const unsigned char *p;
     unsigned char hdr_buf[16], *buf = NULL;
     unsigned int bitlen, magic, length;
-    int isdss;
+    int isdss = -1;
     void *key = NULL;
     EVP_PKEY *pkey = NULL;