diff options
author | venaas <venaas> | 2007-05-03 14:46:36 +0000 |
---|---|---|
committer | venaas <venaas@e88ac4ed-0b26-0410-9574-a7f39faa03bf> | 2007-05-03 14:46:36 +0000 |
commit | f32f6b2ef9cd578920c98b7b60c56b8ed1c4bc1c (patch) | |
tree | 7db10a4b66eb31101bc87123a105bf568c838adf | |
parent | 414b916d07f4a1b475d53627092d24cd5a2a0517 (diff) |
using debug() some more places
git-svn-id: https://svn.testnett.uninett.no/radsecproxy/trunk@71 e88ac4ed-0b26-0410-9574-a7f39faa03bf
-rw-r--r-- | radsecproxy.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/radsecproxy.c b/radsecproxy.c index aceb9d3..e656cbf 100644 --- a/radsecproxy.c +++ b/radsecproxy.c @@ -138,14 +138,11 @@ SSL_CTX *ssl_init() { int i; unsigned long error; - if (!options.tlscertificatefile || !options.tlscertificatekeyfile) { - printf("TLSCertificateFile and TLSCertificateKeyFile must be specified for TLS\n"); - exit(1); - } - if (!options.tlscacertificatefile && !options.tlscacertificatepath) { - printf("CA Certificate file/path need to be configured\n"); - exit(1); - } + if (!options.tlscertificatefile || !options.tlscertificatekeyfile) + debug(DBG_ERR, "TLSCertificateFile and TLSCertificateKeyFile must be specified for TLS"); + + if (!options.tlscacertificatefile && !options.tlscacertificatepath) + debug(DBG_ERR, "CA Certificate file/path need to be configured"); ssl_locks = malloc(CRYPTO_num_locks() * sizeof(pthread_mutex_t)); ssl_lock_count = OPENSSL_malloc(CRYPTO_num_locks() * sizeof(long)); @@ -181,8 +178,8 @@ SSL_CTX *ssl_init() { } while ((error = ERR_get_error())) - err("SSL: %s", ERR_error_string(error, NULL)); - exit(1); + debug(DBG_WARN, "SSL: %s", ERR_error_string(error, NULL)); + debug(DBG_ERR, "Error initialising SSL/TLS"); } void printauth(char *s, unsigned char *t) { |