From: Duy Nguyen Date: Sat, 23 May 2015 01:19:03 GMT Subject: Re: [PATCH/RFC 0/3] using stat() to avoid re-scanning pack dir Message-ID: In-Reply-To: <20150522235116.GA4300@peff.net> On Sat, May 23, 2015 at 6:51 AM, Jeff King wrote: > The other problem is that I'm not sure stat data is enough to notice > when a directory changes. Certainly the mtime should change, but if you > have only one-second resolution on your mtimes, we can be fooled. mtime may or may not change. I based my untracked-cache series entirely on this directory mtime and did some research about it. For UNIXy filesystems on UNIXy OSes, mtime should work as you expect. FAT on Windows does not (but FAT on Linux does..). NTFS works fine according to some MS document. No idea about CIFS. But people often just do open operation of a time and this racy is not an issue. It is only an issue on the busy server side, and you can make sure you run on the right fs+OS. -- Duy