[PATCH] Remove fstring from wb_acct_info
abartlet at samba.org
Wed Oct 31 22:15:12 UTC 2018
On Wed, 2018-10-31 at 17:45 +0100, Samuel Cabrero via samba-technical
> the attached patch removes two fstrings from wb_acct_info struct. The
> reason for this change is because the winbindd group enumeration
> backend functions (ADS in particular) try to allocate an array of
> wb_acct_info as long as the number of groups in the domain, which may
> result in a huge chunk of memory for domains with a large number of
> Please review and push if you agree.
I'm worried about memory lifetimes.
Could you change the talloc_strdup() and normal assignments into
talloc_steal() onto the head of the array at the memory context?
This would ensure the strings stay around as long as the structure
pointing to them.
Authentication Developer, Samba Team https://samba.org
Samba Development and Support, Catalyst IT
More information about the samba-technical