[PATCH] Use talloc_autofree_context() to allocate global memory

Andrew Bartlett abartlet at samba.org
Sun Oct 5 15:03:59 MDT 2014


On Sun, 2014-10-05 at 22:59 +0200, Kamen Mazdrashki wrote:
> On Sun, Oct 5, 2014 at 10:09 PM, Andrew Bartlett <abartlet at samba.org> wrote:
> 
> > On Wed, 2014-10-01 at 02:56 +0200, Kamen Mazdrashki wrote:
> > > Hi team,
> > >
> > > I have rebased the patches on top of latest master.
> > > *
> > >
> > http://git.samba.org/?p=kamenim/samba.git;a=shortlog;h=refs/heads/util-debug-use-autofree-context
> > > * https://github.com/kamenim/samba/pull/1 - for github lovers published
> > as
> > > pull request
> > >
> > > Any reviews (or reviewd-by) are appreciated :)
> >
> > G'Day Kamen,
> >
> > I've pushed the loadparm patches.  I have this nagging doubt about using
> > talloc_autofree_context(), but I can't give a rational explanation.
> >
> > Fair enough :)
> You have much more experience with this code, so your gut feeling is perhaps
> more relevant in this case than a rational explanation.
> 
> Btw, what about this patch:
> https://github.com/kamenim/samba/commit/5154ad8af73735147341a3d2c4d3a40ef2ce399a
> it just introduces a temporary TALLOC_CTX - basically scoping where
> allocations take place
> (+ fairly vague optimization which I have put saucy comment for at
> https://github.com/kamenim/samba/commit/5154ad8af73735147341a3d2c4d3a40ef2ce399a#diff-e2f740724734e0c0de5779fb42a46e78R227
> )

That's fine, Reviewed-by: Andrew Bartlett <abartlet at samba.org>

Andrew Bartlett

-- 
Andrew Bartlett
http://samba.org/~abartlet/
Authentication Developer, Samba Team  http://samba.org
Samba Developer, Catalyst IT          http://catalyst.net.nz/services/samba






More information about the samba-technical mailing list