diff options
author | Luke Bratch <luke@bratch.co.uk> | 2019-05-19 19:45:22 +0100 |
---|---|---|
committer | Luke Bratch <luke@bratch.co.uk> | 2019-05-19 19:45:22 +0100 |
commit | e330fd50d022f1cd4c4623da5970a7e3e8defcff (patch) | |
tree | 2f8c93fd4243f65b07d3a1e904748e2ec5f7b612 /blabouncer.c | |
parent | 55a2e7bd9be3112a8f8b8661b4ccf991d7c0d515 (diff) |
Change defaults (including default and example configuration files) to look for cert.pem and key.pem in ~/.blabouncer/.
Diffstat (limited to 'blabouncer.c')
-rw-r--r-- | blabouncer.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/blabouncer.c b/blabouncer.c index 0e9fda8..45b8648 100644 --- a/blabouncer.c +++ b/blabouncer.c @@ -2025,14 +2025,14 @@ int main(int argc, char *argv[]) { if (settings.clienttls) { // What is the certificate file path? if (!getconfstr("certfile", settings.conffile, settings.certfile)) { - printf("main(): error getting 'certfile' from configuration file.\n"); - exit(1); + // If none provided, set to default + snprintf(settings.certfile, PATH_MAX, "%s/.blabouncer/cert.pem", getenv("HOME")); } // What is the certificate key file path? if (!getconfstr("keyfile", settings.conffile, settings.keyfile)) { - printf("main(): error getting 'keyfile' from configuration file.\n"); - exit(1); + // If none provided, set to default + snprintf(settings.keyfile, PATH_MAX, "%s/.blabouncer/key.pem", getenv("HOME")); } } |