From: Andy Parkins Date: Sat, 26 May 2007 09:12:48 GMT Subject: Re: [PATCH] Fix mishandling of $Id$ expanded in the repository copy in convert.c Message-ID: <200705261012.50530.andyparkins@gmail.com> In-Reply-To: <7vlkfcm2eu.fsf@assigned-by-dhcp.cox.net> On Saturday 2007, May 26, Junio C Hamano wrote: > > for (dst = buf; size; size--) { > > const char *cp; > > + /* Fetch next source character, move the pointer on */ > > char ch = *src++; > > + /* Copy the current character to the destination */ > > *dst++ = ch; > > These are too much. Absolutely. I always find when bug hunting though that I like to comment every block, sometimes to excess, as reminder that I've understood what its doing. I should have done the final pass once I'd found it to clear up the overkill ones :-) > But this is very good, if you fix it to read the current 3 are > "$Id" ;-). "and in the ability to count competition, Andy comes second... let's have a big hand for our runner up" :-) > Thanks for the fix. It would be very nice for the patch to be > accompanied with a new test to expose the bug and demonstrate > that the patch fixes it. I had to jump through quite a few hoops to get the expanded $Id$ into a repository (originally it was because I used an older version of git in one place, and a newer one in another). I'll see what I can do to make a test case though. Andy -- Dr Andy Parkins, M Eng (hons), MIET andyparkins@gmail.com