Fix from HEAD.
This commit is contained in:
parent
616f581650
commit
65a82ef6d7
@ -130,6 +130,8 @@ PKCS7 *PKCS7_sign(X509 *signcert, EVP_PKEY *pkey, STACK_OF(X509) *certs,
|
|||||||
if (flags & PKCS7_STREAM)
|
if (flags & PKCS7_STREAM)
|
||||||
return p7;
|
return p7;
|
||||||
|
|
||||||
|
if(flags & PKCS7_DETACHED)PKCS7_set_detached(p7, 1);
|
||||||
|
|
||||||
if (!(p7bio = PKCS7_dataInit(p7, NULL))) {
|
if (!(p7bio = PKCS7_dataInit(p7, NULL))) {
|
||||||
PKCS7err(PKCS7_F_PKCS7_SIGN,ERR_R_MALLOC_FAILURE);
|
PKCS7err(PKCS7_F_PKCS7_SIGN,ERR_R_MALLOC_FAILURE);
|
||||||
PKCS7_free(p7);
|
PKCS7_free(p7);
|
||||||
@ -138,7 +140,6 @@ PKCS7 *PKCS7_sign(X509 *signcert, EVP_PKEY *pkey, STACK_OF(X509) *certs,
|
|||||||
|
|
||||||
SMIME_crlf_copy(data, p7bio, flags);
|
SMIME_crlf_copy(data, p7bio, flags);
|
||||||
|
|
||||||
if(flags & PKCS7_DETACHED)PKCS7_set_detached(p7, 1);
|
|
||||||
|
|
||||||
if (!PKCS7_dataFinal(p7,p7bio)) {
|
if (!PKCS7_dataFinal(p7,p7bio)) {
|
||||||
PKCS7err(PKCS7_F_PKCS7_SIGN,PKCS7_R_PKCS7_DATASIGN);
|
PKCS7err(PKCS7_F_PKCS7_SIGN,PKCS7_R_PKCS7_DATASIGN);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user