diff options
author | Pauli <pauli@openssl.org> | 2022-09-26 10:10:16 +1000 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2022-09-27 13:58:13 +0200 |
commit | 8bc703c2886c2104f1d472ab681bc7a8c081427a (patch) | |
tree | 555b0c48c9594df7f73cc2b88ba9674947ddd8ee | |
parent | 9690b9737d46cc52cc93682a63b110f5513e7671 (diff) |
Coverity 1515538: resource leak
Reviewed-by: Hugo Landau <hlandau@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19275)
-rw-r--r-- | apps/pkcs12.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/pkcs12.c b/apps/pkcs12.c index f4aef816dd..0c39ed79bd 100644 --- a/apps/pkcs12.c +++ b/apps/pkcs12.c @@ -687,8 +687,10 @@ int pkcs12_main(int argc, char **argv) if ((cb_sk = NCONF_get_section(conf, cb_attr)) != NULL) { for (i = 0; i < sk_CONF_VALUE_num(cb_sk); i++) { val = sk_CONF_VALUE_value(cb_sk, i); - if (strcmp(val->name, "jdkTrustedKeyUsage") == 0) + if (strcmp(val->name, "jdkTrustedKeyUsage") == 0) { obj = OBJ_txt2obj(val->value, 0); + break; + } } } else { ERR_clear_error(); |