apps/ciphers: Fix wrong return value when using -convert parameter
authorTianjia Zhang <tianjia.zhang@linux.alibaba.com>
Mon, 23 Aug 2021 09:40:22 +0000 (17:40 +0800)
committerTomas Mraz <tomas@openssl.org>
Wed, 25 Aug 2021 07:23:01 +0000 (09:23 +0200)
Command 'openssl ciphers -convert <name>' always returns failure,
this patch set the correct return value.

Signed-off-by: Tianjia Zhang <tianjia.zhang@linux.alibaba.com>
Reviewed-by: Paul Yang <kaishen.yy@antfin.com>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16383)

apps/ciphers.c

index 6e4fedd9a769498359ad450188ba0846c88a1f3f..9c494224a11f2793000ad893554f62b590a63f94 100644 (file)
@@ -183,6 +183,7 @@ int ciphers_main(int argc, char **argv)
     if (convert != NULL) {
         BIO_printf(bio_out, "OpenSSL cipher name: %s\n",
                    OPENSSL_cipher_name(convert));
+        ret = 0;
         goto end;
     }