summaryrefslogtreecommitdiffstats
path: root/src/providers/ldap/sdap_async_connection.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/providers/ldap/sdap_async_connection.c')
-rw-r--r--src/providers/ldap/sdap_async_connection.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/providers/ldap/sdap_async_connection.c b/src/providers/ldap/sdap_async_connection.c
index 9871dc210..ec36a6018 100644
--- a/src/providers/ldap/sdap_async_connection.c
+++ b/src/providers/ldap/sdap_async_connection.c
@@ -1119,6 +1119,9 @@ int sdap_cli_connect_recv(struct tevent_req *req,
}
if (gsh) {
+ if (*gsh) {
+ talloc_zfree(*gsh);
+ }
*gsh = talloc_steal(memctx, state->sh);
if (!*gsh) {
return ENOMEM;