summaryrefslogtreecommitdiffstats
path: root/apps/enc.c
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2016-10-19 19:46:38 +0200
committerRichard Levitte <levitte@openssl.org>2016-10-20 09:04:00 +0200
commit0df1caa77b793d055714f4d78d9aac7a985babb8 (patch)
tree87eb3caf0026693522b38c28043f1beb3b37b888 /apps/enc.c
parentaa01b82c69eeb0cfd255174111fc34a7ed5f8429 (diff)
apps: make setup_engine() and release_engine() available always
This removes some #ifndef clutter. Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/1644)
Diffstat (limited to 'apps/enc.c')
-rw-r--r--apps/enc.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/apps/enc.c b/apps/enc.c
index 513f5641b8..8c8f1ef0f9 100644
--- a/apps/enc.c
+++ b/apps/enc.c
@@ -126,10 +126,8 @@ int MAIN(int argc, char **argv)
NULL, *wbio = NULL;
#define PROG_NAME_SIZE 39
char pname[PROG_NAME_SIZE + 1];
-#ifndef OPENSSL_NO_ENGINE
char *engine = NULL;
ENGINE *e = NULL;
-#endif
const EVP_MD *dgst = NULL;
int non_fips_allow = 0;
@@ -323,9 +321,7 @@ int MAIN(int argc, char **argv)
argv++;
}
-#ifndef OPENSSL_NO_ENGINE
e = setup_engine(bio_err, engine, 0);
-#endif
if (cipher && EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER) {
BIO_printf(bio_err,
@@ -675,10 +671,7 @@ int MAIN(int argc, char **argv)
if (bzl != NULL)
BIO_free(bzl);
#endif
-#ifndef OPENSSL_NO_ENGINE
- if (e != NULL)
- release_engine(e);
-#endif
+ release_engine(e);
if (pass)
OPENSSL_free(pass);
apps_shutdown();