[PATCH] Fix several memory and resource leaks

Andreas Schneider asn at samba.org
Tue Aug 14 16:57:41 UTC 2018


On Monday, 13 August 2018 19:29:39 CEST Jeremy Allison wrote:
> On Mon, Aug 13, 2018 at 02:20:15PM +0200, Andreas Schneider wrote:
> > On Sunday, 12 August 2018 15:40:21 CEST Volker Lendecke wrote:
> > > On Fri, Aug 10, 2018 at 04:36:43PM +0200, Andreas Schneider wrote:
> > > > I would keep the patch as it is, but would add an additional patch for
> > > > master which uses a talloc_strackframe(). This would mean we rewrite
> > > > the
> > > > code and pass a talloc memory context to parse_nss_parm(). Then we
> > > > just
> > > > need one TALLOC_FREE(frame) before we leave.
> > > 
> > > Just push it as you like it with my RB+.
> > > 
> > > Sorry for the noise,
> > > 
> > > Volker
> 
> LGTM Andreas, thanks for the fixup !

Ouch, I've introduced a NULL pointer deref :-(

The attached patch fixes it.

-- 
Andreas Schneider                      asn at samba.org
Samba Team                             www.samba.org
GPG-ID:     8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-s3-libads-Free-addr-before-we-free-the-context.patch
Type: text/x-patch
Size: 1177 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20180814/e4112866/0001-s3-libads-Free-addr-before-we-free-the-context.bin>


More information about the samba-technical mailing list