Re: [PATCH] builtin/apply.c: fix a memleak (Fixup, squashable)

2015-03-23 Thread Junio C Hamano
Stefan Beller writes: > Signed-off-by: Stefan Beller > --- > >> By the way, aren't the following also leaking here? >> >>  - the strbuf newlines that starts out as "size" >>  - line[] arrays of preimage and postimage >> > > yes :( > > I think a viable replacement may be below. Yeah, that looks

[PATCH] builtin/apply.c: fix a memleak (Fixup, squashable)

2015-03-23 Thread Stefan Beller
Signed-off-by: Stefan Beller --- > By the way, aren't the following also leaking here? > >  - the strbuf newlines that starts out as "size" >  - line[] arrays of preimage and postimage > yes :( I think a viable replacement may be below. That way the returned value of the function is not -1, but