projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Convert all {NAME}err() in crypto/ to their corresponding ERR_raise() call
[openssl.git]
/
crypto
/
x509
/
x509_trs.c
diff --git
a/crypto/x509/x509_trs.c
b/crypto/x509/x509_trs.c
index 10718c347dda7ac98078ac1110e99dd24d7969aa..dd83dbc52f40b44ad9f06b2f01abde2140fb0409 100644
(file)
--- a/
crypto/x509/x509_trs.c
+++ b/
crypto/x509/x509_trs.c
@@
-113,7
+113,7
@@
int X509_TRUST_get_by_id(int id)
int X509_TRUST_set(int *t, int trust)
{
if (X509_TRUST_get_by_id(trust) == -1) {
int X509_TRUST_set(int *t, int trust)
{
if (X509_TRUST_get_by_id(trust) == -1) {
-
X509err(X509_F_X509_TRUST_SET
, X509_R_INVALID_TRUST);
+
ERR_raise(ERR_LIB_X509
, X509_R_INVALID_TRUST);
return 0;
}
*t = trust;
return 0;
}
*t = trust;
@@
-136,7
+136,7
@@
int X509_TRUST_add(int id, int flags, int (*ck) (X509_TRUST *, X509 *, int),
/* Need a new entry */
if (idx == -1) {
if ((trtmp = OPENSSL_malloc(sizeof(*trtmp))) == NULL) {
/* Need a new entry */
if (idx == -1) {
if ((trtmp = OPENSSL_malloc(sizeof(*trtmp))) == NULL) {
-
X509err(X509_F_X509_TRUST_ADD
, ERR_R_MALLOC_FAILURE);
+
ERR_raise(ERR_LIB_X509
, ERR_R_MALLOC_FAILURE);
return 0;
}
trtmp->flags = X509_TRUST_DYNAMIC;
return 0;
}
trtmp->flags = X509_TRUST_DYNAMIC;
@@
-148,7
+148,7
@@
int X509_TRUST_add(int id, int flags, int (*ck) (X509_TRUST *, X509 *, int),
OPENSSL_free(trtmp->name);
/* dup supplied name */
if ((trtmp->name = OPENSSL_strdup(name)) == NULL) {
OPENSSL_free(trtmp->name);
/* dup supplied name */
if ((trtmp->name = OPENSSL_strdup(name)) == NULL) {
-
X509err(X509_F_X509_TRUST_ADD
, ERR_R_MALLOC_FAILURE);
+
ERR_raise(ERR_LIB_X509
, ERR_R_MALLOC_FAILURE);
goto err;
}
/* Keep the dynamic flag of existing entry */
goto err;
}
/* Keep the dynamic flag of existing entry */
@@
-165,11
+165,11
@@
int X509_TRUST_add(int id, int flags, int (*ck) (X509_TRUST *, X509 *, int),
if (idx == -1) {
if (trtable == NULL
&& (trtable = sk_X509_TRUST_new(tr_cmp)) == NULL) {
if (idx == -1) {
if (trtable == NULL
&& (trtable = sk_X509_TRUST_new(tr_cmp)) == NULL) {
-
X509err(X509_F_X509_TRUST_ADD
, ERR_R_MALLOC_FAILURE);
+
ERR_raise(ERR_LIB_X509
, ERR_R_MALLOC_FAILURE);
goto err;;
}
if (!sk_X509_TRUST_push(trtable, trtmp)) {
goto err;;
}
if (!sk_X509_TRUST_push(trtable, trtmp)) {
-
X509err(X509_F_X509_TRUST_ADD
, ERR_R_MALLOC_FAILURE);
+
ERR_raise(ERR_LIB_X509
, ERR_R_MALLOC_FAILURE);
goto err;
}
}
goto err;
}
}