Re: [PATCH] Make use of stat.ctime configurable
- From
Linus Torvalds <torvalds@linux-foundation.org>
- Date
- Jul 29, 2008, 01:55 UTC
- Message-ID
- <alpine.LFD.1.10.0807281853520.3486@nehalem.linux-foundation.org>
- In-Reply-To
- <7v3alto4r7.fsf@gitster.siamese.dyndns.org>
On Mon, 28 Jul 2008, Junio C Hamano wrote:
> > Ok. While I have your attention on st_ctime, let me ask you a stupid > question. Why does "rename(old, new)" change st_ctime when you move a > regular file?
Hmm. I think that's just a plain POSIX oddity. There's no real "reason" for it, except the historical one: in really old UNIX terms, rename used to be a "link+unlink".
And that "link+unlink" updated ctime because the 'nlink' part of the inode changed. Never mind that it got changed right back ;)
Linus