1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

s4:rpc_server Ensure we talloc_free handles when we delete objects

If we don't talloc_free the handle, we leak the memory onto the long-term
context.

Andrew Bartlett
This commit is contained in:
Andrew Bartlett 2009-10-21 16:07:22 +11:00
parent 398188fb9b
commit a0a787ad78

View File

@ -2300,6 +2300,7 @@ static NTSTATUS dcesrv_samr_DeleteDomainGroup(struct dcesrv_call_state *dce_call
return NT_STATUS_UNSUCCESSFUL;
}
talloc_free(h);
ZERO_STRUCTP(r->out.group_handle);
return NT_STATUS_OK;
@ -2676,6 +2677,7 @@ static NTSTATUS dcesrv_samr_DeleteDomAlias(struct dcesrv_call_state *dce_call, T
return NT_STATUS_UNSUCCESSFUL;
}
talloc_free(h);
ZERO_STRUCTP(r->out.alias_handle);
return NT_STATUS_OK;
@ -2962,6 +2964,7 @@ static NTSTATUS dcesrv_samr_DeleteUser(struct dcesrv_call_state *dce_call, TALLO
return NT_STATUS_UNSUCCESSFUL;
}
talloc_free(h);
ZERO_STRUCTP(r->out.user_handle);
return NT_STATUS_OK;