summaryrefslogtreecommitdiffstats
path: root/apps/pkcs7.c
diff options
context:
space:
mode:
authorjkim <jkim@FreeBSD.org>2016-05-03 18:00:27 +0000
committerjkim <jkim@FreeBSD.org>2016-05-03 18:00:27 +0000
commitacb827e3083196de4c00b67ac9ae3bf860ffd4a9 (patch)
tree2dd85c58056a364765d9ae59d6a1774d41f88523 /apps/pkcs7.c
parent72d32bf80dfdcfe0e69da200b66f195e919653f7 (diff)
downloadFreeBSD-src-acb827e3083196de4c00b67ac9ae3bf860ffd4a9.zip
FreeBSD-src-acb827e3083196de4c00b67ac9ae3bf860ffd4a9.tar.gz
Import OpenSSL 1.0.2h.
Diffstat (limited to 'apps/pkcs7.c')
-rw-r--r--apps/pkcs7.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/apps/pkcs7.c b/apps/pkcs7.c
index 643507f..b677633 100644
--- a/apps/pkcs7.c
+++ b/apps/pkcs7.c
@@ -235,12 +235,16 @@ int MAIN(int argc, char **argv)
i = OBJ_obj2nid(p7->type);
switch (i) {
case NID_pkcs7_signed:
- certs = p7->d.sign->cert;
- crls = p7->d.sign->crl;
+ if (p7->d.sign != NULL) {
+ certs = p7->d.sign->cert;
+ crls = p7->d.sign->crl;
+ }
break;
case NID_pkcs7_signedAndEnveloped:
- certs = p7->d.signed_and_enveloped->cert;
- crls = p7->d.signed_and_enveloped->crl;
+ if (p7->d.signed_and_enveloped != NULL) {
+ certs = p7->d.signed_and_enveloped->cert;
+ crls = p7->d.signed_and_enveloped->crl;
+ }
break;
default:
break;
OpenPOWER on IntegriCloud