projects
/
oweals
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add default operations to EC_METHOD
[oweals/openssl.git]
/
crypto
/
cms
/
cms_enc.c
diff --git
a/crypto/cms/cms_enc.c
b/crypto/cms/cms_enc.c
index 16b42251d19224253b73e8c033e4b22e11a5d420..23adc2ffdabdeaaf91502545e8fe1d9f21dd9196 100644
(file)
--- a/
crypto/cms/cms_enc.c
+++ b/
crypto/cms/cms_enc.c
@@
-1,4
+1,3
@@
-/* crypto/cms/cms_enc.c */
/*
* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
* project.
/*
* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
* project.
@@
-63,8
+62,6
@@
/* CMS EncryptedData Utilities */
/* CMS EncryptedData Utilities */
-DECLARE_ASN1_ITEM(CMS_EncryptedData)
-
/* Return BIO based on EncryptedContentInfo and key */
BIO *cms_EncryptedContent_init_bio(CMS_EncryptedContentInfo *ec)
/* Return BIO based on EncryptedContentInfo and key */
BIO *cms_EncryptedContent_init_bio(CMS_EncryptedContentInfo *ec)
@@
-84,7
+81,7
@@
BIO *cms_EncryptedContent_init_bio(CMS_EncryptedContentInfo *ec)
enc = ec->cipher ? 1 : 0;
b = BIO_new(BIO_f_cipher());
enc = ec->cipher ? 1 : 0;
b = BIO_new(BIO_f_cipher());
- if (
!b
) {
+ if (
b == NULL
) {
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
return NULL;
}
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
return NULL;
}
@@
-132,7
+129,7
@@
BIO *cms_EncryptedContent_init_bio(CMS_EncryptedContentInfo *ec)
/* Generate random session key */
if (!enc || !ec->key) {
tkey = OPENSSL_malloc(tkeylen);
/* Generate random session key */
if (!enc || !ec->key) {
tkey = OPENSSL_malloc(tkeylen);
- if (
!tkey
) {
+ if (
tkey == NULL
) {
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
goto err;
}
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
goto err;
}
@@
-181,7
+178,7
@@
BIO *cms_EncryptedContent_init_bio(CMS_EncryptedContentInfo *ec)
if (piv) {
calg->parameter = ASN1_TYPE_new();
if (piv) {
calg->parameter = ASN1_TYPE_new();
- if (
!calg->parameter
) {
+ if (
calg->parameter == NULL
) {
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
goto err;
}
CMSerr(CMS_F_CMS_ENCRYPTEDCONTENT_INIT_BIO, ERR_R_MALLOC_FAILURE);
goto err;
}
@@
-212,7
+209,7
@@
int cms_EncryptedContent_init(CMS_EncryptedContentInfo *ec,
ec->cipher = cipher;
if (key) {
ec->key = OPENSSL_malloc(keylen);
ec->cipher = cipher;
if (key) {
ec->key = OPENSSL_malloc(keylen);
- if (
!ec->key
)
+ if (
ec->key == NULL
)
return 0;
memcpy(ec->key, key, keylen);
}
return 0;
memcpy(ec->key, key, keylen);
}