diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2023-05-16 10:17:03 +0200 |
---|---|---|
committer | Dr. David von Oheimb <dev@ddvo.net> | 2023-05-25 09:04:35 +0200 |
commit | da7f81d39308f9ecab6fde1f9116ff673ef3f3b3 (patch) | |
tree | 3f1b8310b685dc306c3ff266e552d96829ea1db0 /apps/ts.c | |
parent | APPS/ca: remove spurious errors when certain config file entries are not prov... (diff) | |
download | openssl-da7f81d39308f9ecab6fde1f9116ff673ef3f3b3.tar.xz openssl-da7f81d39308f9ecab6fde1f9116ff673ef3f3b3.zip |
APPS: replace awkward and error-prone pattern by calls to new app_conf_try_string()
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: David von Oheimb <david.von.oheimb@siemens.com>
(Merged from https://github.com/openssl/openssl/pull/20971)
Diffstat (limited to 'apps/ts.c')
-rw-r--r-- | apps/ts.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -375,7 +375,7 @@ static CONF *load_config_file(const char *configfile) const char *p; BIO_printf(bio_err, "Using configuration from %s\n", configfile); - p = NCONF_get_string(conf, NULL, ENV_OID_FILE); + p = app_conf_try_string(conf, NULL, ENV_OID_FILE); if (p != NULL) { BIO *oid_bio = BIO_new_file(p, "r"); if (!oid_bio) @@ -384,8 +384,7 @@ static CONF *load_config_file(const char *configfile) OBJ_create_objects(oid_bio); BIO_free_all(oid_bio); } - } else - ERR_clear_error(); + } if (!add_oid_section(conf)) ERR_print_errors(bio_err); } |