diff options
author | Ben Laurie <ben@openssl.org> | 2000-05-21 15:21:55 +0000 |
---|---|---|
committer | Ben Laurie <ben@openssl.org> | 2000-05-21 15:21:55 +0000 |
commit | 4d29312ce198d00a69c4b0bf572c0de46778ecc9 (patch) | |
tree | 4c2b8aa4124c570f50390fd7b2a87bd135e80236 /crypto/pkcs7/pk7_attr.c | |
parent | c129544f0f85f1bbf7ba65b816db1e899b413799 (diff) |
Yet more typesafety.
Diffstat (limited to 'crypto/pkcs7/pk7_attr.c')
-rw-r--r-- | crypto/pkcs7/pk7_attr.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/crypto/pkcs7/pk7_attr.c b/crypto/pkcs7/pk7_attr.c index edea2359b3..f22a708358 100644 --- a/crypto/pkcs7/pk7_attr.c +++ b/crypto/pkcs7/pk7_attr.c @@ -12,6 +12,7 @@ #include <openssl/asn1.h> #include <openssl/pem.h> #include <openssl/pkcs7.h> +#include <openssl/x509.h> #include <openssl/err.h> int PKCS7_add_attrib_smimecap(PKCS7_SIGNER_INFO *si, STACK_OF(X509_ALGOR) *cap) @@ -42,16 +43,17 @@ int PKCS7_add_attrib_smimecap(PKCS7_SIGNER_INFO *si, STACK_OF(X509_ALGOR) *cap) V_ASN1_SEQUENCE, seq); } -STACK *PKCS7_get_smimecap(PKCS7_SIGNER_INFO *si) +STACK_OF(X509_ALGOR) *PKCS7_get_smimecap(PKCS7_SIGNER_INFO *si) { ASN1_TYPE *cap; unsigned char *p; cap = PKCS7_get_signed_attribute(si, NID_SMIMECapabilities); if (!cap) return NULL; p = cap->value.sequence->data; - return d2i_ASN1_SET (NULL, &p, cap->value.sequence->length, - (char *(*)())d2i_X509_ALGOR, X509_ALGOR_free, V_ASN1_SEQUENCE, - V_ASN1_UNIVERSAL); + return d2i_ASN1_SET_OF_X509_ALGOR(NULL, &p, + cap->value.sequence->length, + d2i_X509_ALGOR, X509_ALGOR_free, + V_ASN1_SEQUENCE, V_ASN1_UNIVERSAL); } /* Basic smime-capabilities OID and optional integer arg */ |