about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--server.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/server.c b/server.c
index 5ca517c..cb11d84 100644
--- a/server.c
+++ b/server.c
@@ -46,21 +46,10 @@ void serverConfig(bool insecure, const char *cert, const char *priv) {
 	}
 
 	if (cert) {
-		error = tls_config_set_cert_file(config, cert);
+		error = tls_config_set_keypair_file(config, cert, (priv ? priv : cert));
 		if (error) {
 			errx(
-				EX_SOFTWARE, "tls_config_set_cert_file: %s",
-				tls_config_error(config)
-			);
-		}
-	}
-
-	if (cert && !priv) priv = cert;
-	if (priv) {
-		error = tls_config_set_key_file(config, priv);
-		if (error) {
-			errx(
-				EX_SOFTWARE, "tls_config_set_key_file: %s",
+				EX_SOFTWARE, "tls_config_set_keypair_file: %s",
 				tls_config_error(config)
 			);
 		}
nroe 2022-06-05FIRST SHOW IN 2.5 YEARS BABEY!!!June McEnroe 2022-06-03Set line number on File linesJune McEnroe 2022-06-03Stop polling stdin after EOFJune McEnroe 2022-06-02Set TABSIZE=4June McEnroe 2022-06-02Do basic match highlightingJune McEnroe 2022-06-02Clean up parsing a littleJune McEnroe 2022-06-02Don't duplicate path stringJune McEnroe 2022-06-02Use stderr instead of /dev/tty, realloc buffer if lines too longJune McEnroe 2022-06-02Add initial working version of qfJune McEnroe 2022-05-29Set prompt for okshJune McEnroe