[PATCH] fix compare symlink against readlink not data
[git/git.git] / diff-files.c
index 0cf2c24..c51edc3 100644 (file)
@@ -111,7 +111,7 @@ int main(int argc, char **argv)
                        continue;
                }
  
-               if (stat(ce->name, &st) < 0) {
+               if (lstat(ce->name, &st) < 0) {
                        if (errno != ENOENT) {
                                perror(ce->name);
                                continue;