summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/winbind/wb_samba3_cmd.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source4/winbind/wb_samba3_cmd.c b/source4/winbind/wb_samba3_cmd.c
index 55a763f91e..22f9fd5f5a 100644
--- a/source4/winbind/wb_samba3_cmd.c
+++ b/source4/winbind/wb_samba3_cmd.c
@@ -807,7 +807,14 @@ NTSTATUS wbsrv_samba3_getpwent(struct wbsrv_samba3_call *s3call)
NTSTATUS wbsrv_samba3_endpwent(struct wbsrv_samba3_call *s3call)
{
+ struct wbsrv_pwent *pwent =
+ talloc_get_type(s3call->wbconn->protocol_private_data,
+ struct wbsrv_pwent);
DEBUG(5, ("wbsrv_samba3_endpwent called\n"));
+
+ talloc_free(pwent);
+
+ s3call->wbconn->protocol_private_data = NULL;
s3call->response.result = WINBINDD_OK;
return NT_STATUS_OK;
}