]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#8755 Do not close the default SockBuf a second time
authorOndřej Kuzník <ondra@openldap.org>
Tue, 14 May 2019 11:54:58 +0000 (12:54 +0100)
committerQuanah Gibson-Mount <quanah@openldap.org>
Thu, 20 Jun 2019 17:41:37 +0000 (17:41 +0000)
libraries/libldap/unbind.c

index 00d3df211444eb927f397fac03b7f68b0ee0c21e..b1597cb03d42071f098a4e3f97fd698801a872e7 100644 (file)
@@ -131,7 +131,9 @@ ldap_ld_free(
        }
        LDAP_MUTEX_UNLOCK( &ld->ld_res_mutex );
 
-       ber_sockbuf_free( ld->ld_sb );
+       /* Should already be closed by ldap_free_connection which knows not to free
+        * this one */
+       ber_int_sb_destroy( ld->ld_sb );
 
        LDAP_MUTEX_LOCK( &ld->ld_ldopts_mutex );