summaryrefslogtreecommitdiffstats
path: root/apps/cms.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2016-08-24 13:36:07 +0100
committerMatt Caswell <matt@openssl.org>2016-08-24 14:49:40 +0100
commitefba7787cd0036d667943070265ca8aef59e9d00 (patch)
treea2f56a2e3a56013af291686edbfa7759737cd4c0 /apps/cms.c
parent0a307450bfdd570a09235a7ba16d6c8243bbe275 (diff)
Clarify the error messages in 08f6ae5b28
Ensure it is clear to the user why there has been an error. Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'apps/cms.c')
-rw-r--r--apps/cms.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/apps/cms.c b/apps/cms.c
index 9c41a97ec5..b9eec2432a 100644
--- a/apps/cms.c
+++ b/apps/cms.c
@@ -413,8 +413,8 @@ int cms_main(int argc, char **argv)
break;
case OPT_SECRETKEY:
if (secret_key != NULL) {
- /* Cannot be supplied twice */
- BIO_printf(bio_err, "Invalid key %s\n", opt_arg());
+ BIO_printf(bio_err, "Invalid key (supplied twice) %s\n",
+ opt_arg());
goto opthelp;
}
secret_key = OPENSSL_hexstr2buf(opt_arg(), &ltmp);
@@ -426,8 +426,8 @@ int cms_main(int argc, char **argv)
break;
case OPT_SECRETKEYID:
if (secret_keyid != NULL) {
- /* Cannot be supplied twice */
- BIO_printf(bio_err, "Invalid id %s\n", opt_arg());
+ BIO_printf(bio_err, "Invalid id (supplied twice) %s\n",
+ opt_arg());
goto opthelp;
}
secret_keyid = OPENSSL_hexstr2buf(opt_arg(), &ltmp);
@@ -442,8 +442,8 @@ int cms_main(int argc, char **argv)
break;
case OPT_ECONTENT_TYPE:
if (econtent_type != NULL) {
- /* Cannot be supplied twice */
- BIO_printf(bio_err, "Invalid OID %s\n", opt_arg());
+ BIO_printf(bio_err, "Invalid OID (supplied twice) %s\n",
+ opt_arg());
goto opthelp;
}
econtent_type = OBJ_txt2obj(opt_arg(), 0);