From: Junio C Hamano Date: Sat, 12 Jan 2019 03:02:46 GMT Subject: Re: [PATCH 1/6] get_super_prefix(): copy getenv() result Message-ID: In-Reply-To: <20190111221500.GA10188@sigill.intra.peff.net> Jeff King writes: > The return value of getenv() is not guaranteed to remain valid across > multiple calls (nor across calls to setenv()). Since this function > caches the result for the length of the program, we must make a copy to > ensure that it is still valid when we need it. > > Reported-by: Yngve N. Pettersen > Signed-off-by: Jeff King > --- Makes sense. Thanks.