Ok, with these patches, the strace of the index preload looks very clean, and has the required tests for the directory components too: ... 26504 lstat("connect.c", {st_mode=S_IFREG|0664, st_size=14312, ...}) = 0 26504 lstat("contrib", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0 26504 lstat("contrib/README", {st_mode=S_IFREG|0664, st_size=2113, ...}) = 0 26504 lstat("contrib/blameview", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0 26504 lstat("contrib/blameview/blameview.perl", {st_mode=S_IFREG|0775, st_size=3776, ...}) = 0 ... ie now it actualyl verifies that the directories leading up to filenames are really directories by doing lstat() on them. And the symlink cache means that it doesn't do it for every single pathname, only for the first lookup per thread and directory. Maybe Kjetil wants to check the changes, but quite frankly, it looked pretty trivial to make that whole has_symlink_leading_path() be thread-safe. Linus -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html