summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--radsecproxy.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/radsecproxy.c b/radsecproxy.c
index 5673052..dfe8141 100644
--- a/radsecproxy.c
+++ b/radsecproxy.c
@@ -1647,10 +1647,11 @@ void *clientwr(void *arg) {
if (server->conf->type == 'U') {
if ((server->sock = connecttoserver(server->conf->addrinfo)) < 0)
debugx(1, DBG_ERR, "clientwr: connecttoserver failed");
- server->connectionok = 1;
} else
tlsconnect(server, NULL, "new client");
+ server->connectionok = 1;
+
if (pthread_create(&clientrdth, NULL, clientrd, (void *)server))
debugx(1, DBG_ERR, "clientwr: pthread_create failed");