diff options
author | beck <> | 2014-04-26 18:56:38 +0000 |
---|---|---|
committer | beck <> | 2014-04-26 18:56:38 +0000 |
commit | e7dbd7a1e2ad3e12dafa2919bc8603d60416ea4d (patch) | |
tree | dff54039de6c4454b05953e2ce78edfc5693e6b5 /src/lib/libcrypto/x509/x509_att.c | |
parent | a1c73b72875dcb25545f111b3779cf0f0ebf9c88 (diff) | |
download | openbsd-e7dbd7a1e2ad3e12dafa2919bc8603d60416ea4d.tar.gz openbsd-e7dbd7a1e2ad3e12dafa2919bc8603d60416ea4d.tar.bz2 openbsd-e7dbd7a1e2ad3e12dafa2919bc8603d60416ea4d.zip |
Replace all use of ERR_add_error_data with ERR_asprintf_error_data.
This avoids a lot of ugly gymnastics to do snprintfs before sending the
bag of strings to ERR, and eliminates at least one place in dso_dlfctn.c
where it was being called with the incorrect number of arguments and
using random things off the stack as addresses of strings.
ok krw@, jsing@
Diffstat (limited to 'src/lib/libcrypto/x509/x509_att.c')
-rw-r--r-- | src/lib/libcrypto/x509/x509_att.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/libcrypto/x509/x509_att.c b/src/lib/libcrypto/x509/x509_att.c index 5699568998..ef922c7c83 100644 --- a/src/lib/libcrypto/x509/x509_att.c +++ b/src/lib/libcrypto/x509/x509_att.c | |||
@@ -282,7 +282,7 @@ X509_ATTRIBUTE_create_by_txt(X509_ATTRIBUTE **attr, const char *atrname, | |||
282 | if (obj == NULL) { | 282 | if (obj == NULL) { |
283 | X509err(X509_F_X509_ATTRIBUTE_CREATE_BY_TXT, | 283 | X509err(X509_F_X509_ATTRIBUTE_CREATE_BY_TXT, |
284 | X509_R_INVALID_FIELD_NAME); | 284 | X509_R_INVALID_FIELD_NAME); |
285 | ERR_add_error_data(2, "name=", atrname); | 285 | ERR_asprintf_error_data("name=%s", atrname); |
286 | return (NULL); | 286 | return (NULL); |
287 | } | 287 | } |
288 | nattr = X509_ATTRIBUTE_create_by_OBJ(attr, obj, type, bytes, len); | 288 | nattr = X509_ATTRIBUTE_create_by_OBJ(attr, obj, type, bytes, len); |