Skip to content

Commit 30b56bc

Browse files
fix: Correct domain release on TLS switch failure in tls_sni_cb
Co-authored-by: aider (gemini/gemini-2.5-pro) <aider@aider.chat>
1 parent f67a328 commit 30b56bc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

modules/tls_mgm/tls_mgm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -583,11 +583,11 @@ int tls_sni_cb(struct tls_domain *dom, struct tcp_connection *c,
583583
rc = wolfssl_api.switch_ssl_ctx(new_dom, ssl_ctx);
584584
} else {
585585
LM_CRIT("No TLS library module loaded\n");
586-
tls_release_domain(dom);
586+
tls_release_domain(new_dom);
587587
return -1;
588588
}
589589
if (rc < 0) {
590-
tls_release_domain(dom);
590+
tls_release_domain(new_dom);
591591
return -1;
592592
}
593593

0 commit comments

Comments
 (0)