Subject: Re: [PATCH v2 2/3] diff: add -I<regex> that ignores matching changes

From: Junio C Hamano <[email-masked]>
Date: Tue, 13 Oct 2020 08:53:43 -0700

Johannes Schindelin <[email-masked]> writes:

> Oh wow, from a cursory look it seems as if the diff machinery was not
> exactly careful with releasing memory. I might be mistaken, but if I am
> not, then this would deserve a separate patch series, methinks.

I wouldn't be surprised if newer parts of it is much less careful
than the older parts of the machinery.  Most callers of the diff
machinery, including "log -p" that repeatedly generates patches,
would however run just a single setup for the entire series of diff
invocations before tearing it down AFIAR, so leaking the result of
parsing the command line option may not be such a big deal to these
callers.  But some callers added recently may not follow the access
pattern, in which case the machinery may have to be made more
leakproof.

Thanks.