Re: [PATCH v2 14/25] setup_discovered_git_dir(): help static analysis
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- May 2, 2017, 12:38 UTC
- Message-ID
- <alpine.DEB.2.20.1705021438300.3480@virtualbox>
- In-Reply-To
- <xmqq4lx3ewrc.fsf@gitster.mtv.corp.google.com>
Hi Junio,
On Mon, 1 May 2017, Junio C Hamano wrote:
Show 12 quoted lines
> Johannes Schindelin <johannes.schindelin@gmx.de> writes: > > > Coverity reported a memory leak in this function. However, it can only > > be called once, as setup_git_directory() changes global state and hence > > is not reentrant. > > > > Mark the variable as static to indicate that this is a singleton. > > > > Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> > > --- > > Does something different from what is explained above. Rebase gotcha?
That, or just a brain fart.
Thanks, will send an updated iteration.
Ciao, Dscho