summaryrefslogtreecommitdiffstats
path: root/apps/storeutl.c
diff options
context:
space:
mode:
authorDr. David von Oheimb <David.von.Oheimb@siemens.com>2020-06-27 10:28:45 +0200
committerDr. David von Oheimb <David.von.Oheimb@siemens.com>2020-08-04 09:17:47 +0200
commit57c05c57c3aab2755ec6eeae5d1800ac9cbd2f6d (patch)
treee880975a593a1b24c3d9276fe4cde84dfd2b9702 /apps/storeutl.c
parent02ae130e3dd1e4b4252692f65cb1f975bfe47935 (diff)
apps: Correct and extend diagnostics of parse_name()
Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/12296)
Diffstat (limited to 'apps/storeutl.c')
-rw-r--r--apps/storeutl.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/apps/storeutl.c b/apps/storeutl.c
index 95af277260..66fd423ab0 100644
--- a/apps/storeutl.c
+++ b/apps/storeutl.c
@@ -157,11 +157,9 @@ int storeutl_main(int argc, char *argv[])
prog);
goto end;
}
- if ((subject = parse_name(opt_arg(), MBSTRING_UTF8, 1)) == NULL) {
- BIO_printf(bio_err, "%s: can't parse subject argument.\n",
- prog);
+ subject = parse_name(opt_arg(), MBSTRING_UTF8, 1, "subject");
+ if (subject == NULL)
goto end;
- }
break;
case OPT_CRITERION_ISSUER:
if (criterion != 0
@@ -177,11 +175,9 @@ int storeutl_main(int argc, char *argv[])
prog);
goto end;
}
- if ((issuer = parse_name(opt_arg(), MBSTRING_UTF8, 1)) == NULL) {
- BIO_printf(bio_err, "%s: can't parse issuer argument.\n",
- prog);
+ issuer = parse_name(opt_arg(), MBSTRING_UTF8, 1, "issuer");
+ if (issuer == NULL)
goto end;
- }
break;
case OPT_CRITERION_SERIAL:
if (criterion != 0