diff options
author | Rich Salz <rsalz@openssl.org> | 2015-04-25 15:41:29 -0400 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2015-04-25 15:41:29 -0400 |
commit | 333b070ec06d7a67538ee9d5312656a19e802dc1 (patch) | |
tree | aa630fe4f89d2333f82e2aeeba61f66e86e1349c /apps/ca.c | |
parent | c54cc2b15d96944fcf13ccd24baca79f9593cbf0 (diff) | |
download | openssl-333b070ec06d7a67538ee9d5312656a19e802dc1.tar.gz |
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/ca.c')
-rw-r--r-- | apps/ca.c | 17 |
1 files changed, 6 insertions, 11 deletions
@@ -292,17 +292,15 @@ int ca_main(int argc, char **argv) X509_CRL *crl = NULL; const EVP_MD *dgst = NULL; char *configfile = NULL, *md = NULL, *policy = NULL, *keyfile = NULL; - char *certfile = NULL, *crl_ext = NULL, *crlnumberfile = NULL, *enddate = - NULL; + char *certfile = NULL, *crl_ext = NULL, *crlnumberfile = NULL; char *infile = NULL, *spkac_file = NULL, *ss_cert_file = NULL; char *extensions = NULL, *extfile = NULL, *key = NULL, *passinarg = NULL; char *outdir = NULL, *outfile = NULL, *rev_arg = NULL, *ser_status = NULL; - char *serialfile = NULL, *startdate = NULL, *subj = NULL, *tmp_email_dn = - NULL; - char *prog; - char *const *pp; - char *dbfile = NULL, *engine = NULL, *f, *randfile = NULL, *tofree = NULL; + char *serialfile = NULL, *startdate = NULL, *subj = NULL; + char *prog, *enddate = NULL, *tmp_email_dn = NULL; + char *dbfile = NULL, *f, *randfile = NULL, *tofree = NULL; char buf[3][BSIZE]; + char *const *pp; const char *p; int create_ser = 0, free_key = 0, total = 0, total_done = 0; int batch = 0, default_op = 1, doupdatedb = 0, ext_copy = EXT_COPY_NONE; @@ -488,7 +486,7 @@ opthelp: rev_type = REV_CA_COMPROMISE; break; case OPT_ENGINE: - engine = opt_arg(); + e = setup_engine(opt_arg(), 0); break; } } @@ -542,9 +540,6 @@ end_of_options: OPENSSL_free(tofree); tofree = NULL; } -#ifndef OPENSSL_NO_ENGINE - e = setup_engine(engine, 0); -#endif /* Lets get the config section we are using */ if (section == NULL) { |