Commit 8138c77f authored by Vladimír Čunát's avatar Vladimír Čunát

daemon/tls: don't segfault if gnutls_priority_* fails

parent 2de02515
......@@ -307,6 +307,10 @@ static void _tcp_accept(uv_stream_t *master, int status, bool tls)
timeout += KR_CONN_RTT_MAX * 3;
if (!session->tls_ctx) {
session->tls_ctx = tls_new(master->loop->data);
if (!session->tls_ctx) {
worker_session_close(session);
return;
}
session->tls_ctx->c.session = session;
session->tls_ctx->c.handshake_state = TLS_HS_IN_PROGRESS;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment