mirror of
https://github.com/samba-team/samba.git
synced 2025-08-02 00:22:11 +03:00
Fix for previous checkin. Only use talloc on unmarshalling or we'll
leak memory.
Jeremy.
(This used to be commit 07a76eb2e0
)
This commit is contained in:
@ -4619,9 +4619,11 @@ BOOL samr_io_r_query_aliasmem(const char *desc, SAMR_R_QUERY_ALIASMEM * r_u,
|
||||
if(!prs_uint32("num_sids1", ps, depth, &r_u->num_sids1))
|
||||
return False;
|
||||
|
||||
ptr_sid = talloc(ps->mem_ctx, sizeof(uint32) * r_u->num_sids1);
|
||||
if (!ptr_sid) {
|
||||
return False;
|
||||
if (UNMARSHALLING(ps)) {
|
||||
ptr_sid = talloc(ps->mem_ctx, sizeof(uint32) * r_u->num_sids1);
|
||||
if (!ptr_sid) {
|
||||
return False;
|
||||
}
|
||||
}
|
||||
|
||||
for (i = 0; i < r_u->num_sids1; i++) {
|
||||
|
Reference in New Issue
Block a user