git.samba.org
/
ira
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
3d94b28
)
s4:auth/sam.c - change base context for the "tmp_ctx" context in "authsam_expand_nest...
author
Matthias Dieter Wallnöfer
<mwallnoefer@yahoo.de>
Thu, 4 Mar 2010 21:18:10 +0000
(22:18 +0100)
committer
Matthias Dieter Wallnöfer
<mwallnoefer@yahoo.de>
Thu, 4 Mar 2010 21:18:10 +0000
(22:18 +0100)
Better use the "res_sids_ctx" as base context for the "tmp_ctx" and not the
long-living "sam_ctx"/"ldb" context to prevent memory leaks.
source4/auth/sam.c
patch
|
blob
|
history
diff --git
a/source4/auth/sam.c
b/source4/auth/sam.c
index 20efc3684ab512d01698b8e97dee9fe2d7076344..fc3e810ef7f5fe0546d476a695ccecae0e0d763c 100644
(file)
--- a/
source4/auth/sam.c
+++ b/
source4/auth/sam.c
@@
-336,7
+336,7
@@
_PUBLIC_ NTSTATUS authsam_expand_nested_groups(struct ldb_context *sam_ctx,
++(*num_res_sids);
}
++(*num_res_sids);
}
- tmp_ctx = talloc_new(
sam
_ctx);
+ tmp_ctx = talloc_new(
res_sids
_ctx);
ret = gendb_search(sam_ctx, tmp_ctx, NULL, &res, attrs,
"objectSid=%s", ldap_encode_ndr_dom_sid(tmp_ctx, sid));
ret = gendb_search(sam_ctx, tmp_ctx, NULL, &res, attrs,
"objectSid=%s", ldap_encode_ndr_dom_sid(tmp_ctx, sid));