Code

grep: micro-optimize hit collection for AND nodes
[git.git] / diff-no-index.c
index 2d541d9aba11ee69525a6a1ef5da6f8a61e9e65e..0a14268ba952da5ff66be753cc0cc147ba64ee2b 100644 (file)
@@ -40,7 +40,7 @@ static int get_mode(const char *path, int *mode)
                *mode = 0;
        else if (!strcmp(path, "-"))
                *mode = create_ce_mode(0666);
-       else if (stat(path, &st))
+       else if (lstat(path, &st))
                return error("Could not access '%s'", path);
        else
                *mode = st.st_mode;