When apps_startup() fails, exit with a failure code and a message
authorRichard Levitte <levitte@openssl.org>
Fri, 30 Jun 2017 18:47:45 +0000 (20:47 +0200)
committerRichard Levitte <levitte@openssl.org>
Sat, 1 Jul 2017 08:03:21 +0000 (10:03 +0200)
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3816)

apps/openssl.c

index b2d4e6f208a878b20048a8da5ba14d2fce466d73..2a140718ab3fada504fa36ce2231733cc2f3f922 100644 (file)
@@ -144,8 +144,13 @@ int main(int argc, char *argv[])
         return 1;
     }
 
-    if (!apps_startup())
+    if (!apps_startup()) {
+        BIO_printf(bio_err,
+                   "FATAL: Startup failure (dev note: apps_startup() failed)\n");
+        ERR_print_errors(bio_err);
+        ret = 1;
         goto end;
+    }
 
     prog = prog_init();
     pname = opt_progname(argv[0]);