From: Junio C Hamano Date: Tue, 29 Jul 2008 00:46:05 GMT Subject: Re: [PATCHv2] git-mv: Keep moved index entries inact Message-ID: <7vod4ho6uq.fsf@gitster.siamese.dyndns.org> In-Reply-To: <20080729001751.GH10151@machine.or.cz> Petr Baudis writes: > On Mon, Jul 28, 2008 at 12:19:19PM -0700, Junio C Hamano wrote: >> We need to refresh the entry to pick up potential ctime changes. >> >> read-cache.c | 7 ++++++- >> builtin-ls-files.c | 21 +++++++++++++++------ >> 2 files changed, 21 insertions(+), 7 deletions(-) >> >> diff --git a/read-cache.c b/read-cache.c >> index 1cae361..834096f 100644 > > Oops, silly me. Sorry for being slower than you at fixing this. ;-) I did think about ctime issues when I applied the patch. rename(2) is hardlink to new name followed by unlink of old name, so internally link count changes twice (and the first "link to new" can exceed max links and is even allowed to make the whole thing fail); but I do not think of any other reason for this change in ctime.