Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
test/send-email: --[no-]xmailer tests
[gitweb.git]
/
read-cache.c
diff --git
a/read-cache.c
b/read-cache.c
index 5d3c8bd4aaffda9915a3fd62d9d9800f4ac8baff..6f0057fe66a59e1239703ee4458de200304f727a 100644
(file)
--- a/
read-cache.c
+++ b/
read-cache.c
@@
-1064,6
+1064,14
@@
static struct cache_entry *refresh_cache_ent(struct index_state *istate,
return ce;
}
+ if (has_symlink_leading_path(ce->name, ce_namelen(ce))) {
+ if (ignore_missing)
+ return ce;
+ if (err)
+ *err = ENOENT;
+ return NULL;
+ }
+
if (lstat(ce->name, &st) < 0) {
if (ignore_missing && errno == ENOENT)
return ce;