Re: [PATCH v8 18/19] branch: use ref-filter printing APIs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Dec 12, 2016 at 04:50:20PM +0530, Karthik Nayak wrote:

> > This caller never stores the return value, and it ends up leaking. So I
> > wonder if you wanted "static struct strbuf" in the first place (and that
> > would explain the strbuf_reset() in your function).
> 
> Ah! Yes this should be 'static struct strbuf' indeed, I blindly copied Junio's
> suggestion.
> 
> strbuf_detach() is also a better way to go.

One of the other, though. If it's static, then you _don't_ want to
detach.

-Peff



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]