Code hygiene; initialize some pointers.
authorMouse <mouse008@gmail.com>
Tue, 10 Oct 2017 18:02:56 +0000 (14:02 -0400)
committerRich Salz <rsalz@openssl.org>
Mon, 16 Oct 2017 18:46:53 +0000 (14:46 -0400)
CLA: trivial

Reviewed-by: Andy Polyakov <appro@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4515)

crypto/cms/cms_sd.c
crypto/pkcs7/pk7_doit.c

index a31e8495ca74e180a29c702e3739a6385adfd5a8..764781688b00ae3d2c931cff7ebd0207a0b83b63 100644 (file)
@@ -635,7 +635,7 @@ int cms_SignedData_final(CMS_ContentInfo *cms, BIO *chain)
 int CMS_SignerInfo_sign(CMS_SignerInfo *si)
 {
     EVP_MD_CTX *mctx = si->mctx;
-    EVP_PKEY_CTX *pctx;
+    EVP_PKEY_CTX *pctx = NULL;
     unsigned char *abuf = NULL;
     int alen;
     size_t siglen;
index 0ff9e9364e323863bab52f5ab1226a5dcd78c611..9883a4f02c2ea0e6db45c9082b61f2e60bbc128b 100644 (file)
@@ -813,7 +813,7 @@ int PKCS7_dataFinal(PKCS7 *p7, BIO *bio)
 int PKCS7_SIGNER_INFO_sign(PKCS7_SIGNER_INFO *si)
 {
     EVP_MD_CTX *mctx;
-    EVP_PKEY_CTX *pctx;
+    EVP_PKEY_CTX *pctx = NULL;
     unsigned char *abuf = NULL;
     int alen;
     size_t siglen;