From: Willy Tarreau Date: Thu, 10 Aug 2006 05:42:11 GMT Subject: Re: What's in git.git, and announcing GIT 1.4.2-rc4 Message-ID: <20060810054211.GA28387@1wt.eu> In-Reply-To: <7vfyg5xi02.fsf@assigned-by-dhcp.cox.net> On Wed, Aug 09, 2006 at 10:43:57PM -0700, Junio C Hamano wrote: > Junio C Hamano writes: > > > Willy Tarreau writes: > > > >> I encountered a problem in 1.4.1 and 1.4-git about 2 weeks ago > >> (I've not tried 1.4.2-rc4 yet). When applying a git patch which > >> contains a symlink, the symlink created on the filesystem sometimes > >> has a wrong name with some chars appended to its end. > > > > Thanks. I can reproduce this, and am looking into it. > > Found it. The patch application mechanism uses a counted string > (char *buf with ulong size) to hold the result, and the code > stupidly threw the buf to symlink(2), without making it NUL > terminated. Excellent ! That means that under some circumstances, it might even have corrupted the very first link, and not necessarily only the second and other ones. Thanks for having fixed it that fast. Cheers, Willy