diff options
author | Rich Salz <rsalz@openssl.org> | 2015-04-25 21:41:29 +0200 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2015-04-25 21:41:29 +0200 |
commit | 333b070ec06d7a67538ee9d5312656a19e802dc1 (patch) | |
tree | aa630fe4f89d2333f82e2aeeba61f66e86e1349c /apps/smime.c | |
parent | Add missing BIO_flush() calls (diff) | |
download | openssl-333b070ec06d7a67538ee9d5312656a19e802dc1.tar.xz openssl-333b070ec06d7a67538ee9d5312656a19e802dc1.zip |
fewer NO_ENGINE #ifdef's
Make setup_engine be a dummy if NO_ENGINE is enabled.
The option is not enabled if NO_ENGINE is enabled, so the one "wasted"
variable just sits there. Removes some variables and code.
Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'apps/smime.c')
-rw-r--r-- | apps/smime.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/apps/smime.c b/apps/smime.c index 532446f49f..0c683f5b3c 100644 --- a/apps/smime.c +++ b/apps/smime.c @@ -164,7 +164,7 @@ int smime_main(int argc, char **argv) X509_VERIFY_PARAM *vpm = NULL; const EVP_CIPHER *cipher = NULL; const EVP_MD *sign_md = NULL; - char *CAfile = NULL, *CApath = NULL, *inrand = NULL, *engine = NULL; + char *CAfile = NULL, *CApath = NULL, *inrand = NULL; char *certfile = NULL, *keyfile = NULL, *contfile = NULL, *prog; char *infile = NULL, *outfile = NULL, *signerfile = NULL, *recipfile = NULL; @@ -177,9 +177,7 @@ int smime_main(int argc, char **argv) int informat = FORMAT_SMIME, outformat = FORMAT_SMIME, keyform = FORMAT_PEM; int vpmtouched = 0, rv = 0; -#ifndef OPENSSL_NO_ENGINE ENGINE *e = NULL; -#endif if ((vpm = X509_VERIFY_PARAM_new()) == NULL) return 1; @@ -276,7 +274,7 @@ int smime_main(int argc, char **argv) need_rand = 1; break; case OPT_ENGINE: - engine = opt_arg(); + e = setup_engine(opt_arg(), 0); break; case OPT_PASSIN: passinarg = opt_arg(); @@ -408,10 +406,6 @@ int smime_main(int argc, char **argv) } else if (!operation) goto opthelp; -#ifndef OPENSSL_NO_ENGINE - e = setup_engine(engine, 0); -#endif - if (!app_passwd(passinarg, NULL, &passin, NULL)) { BIO_printf(bio_err, "Error getting password\n"); goto end; |