]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Do not call isc_tlsctx_free() on TLS listener creation failure
authorArtem Boldariev <artem@boldariev.com>
Fri, 8 Oct 2021 08:38:26 +0000 (11:38 +0300)
committerArtem Boldariev <artem@boldariev.com>
Wed, 13 Oct 2021 14:50:42 +0000 (17:50 +0300)
This commit removes a superfluous call to isc_tlsctx_free() which was
leading to double free() error in a case of a TLS listener creation
failure.

The call is superfluous because the TLS context object is supposed to
be destroyed in ns_listenelt_destroy() only.

lib/ns/interfacemgr.c

index 72b86dc0c9f660fdaac938d5f530c7cd9940c5ac..9673902b61eb629626d596dda0c935d74285f735 100644 (file)
@@ -511,7 +511,6 @@ ns_interface_listentls(ns_interface_t *ifp, isc_tlsctx_t *sslctx) {
                isc_log_write(IFMGR_COMMON_LOGARGS, ISC_LOG_ERROR,
                              "creating TLS socket: %s",
                              isc_result_totext(result));
-               isc_tlsctx_free(&sslctx);
                return (result);
        }