summaryrefslogtreecommitdiff
path: root/attr.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-09-17 15:55:41 -0700
committerJunio C Hamano <gitster@pobox.com>2012-09-17 15:55:41 -0700
commitd6fb62474ee4772ceca815122f21a4198e4f22f2 (patch)
treef718fe941f47e8f4e871088ed057db4bbb46921d /attr.c
parentd6e32f6af5b806b4af18b1a4eba578a859a26056 (diff)
parent8e950dab86eafa8f4ea671fab593ca6210bc2e15 (diff)
downloadgit-d6fb62474ee4772ceca815122f21a4198e4f22f2.tar.gz
Merge branch 'jk/config-warn-on-inaccessible-paths'
The attribute system may be asked for a path that itself or its leading directories no longer exists in the working tree. Failure to open per-directory .gitattributes with error status other than ENOENT and ENOTDIR are diagnosed. * jk/config-warn-on-inaccessible-paths: attr: failure to open a .gitattributes file is OK with ENOTDIR
Diffstat (limited to 'attr.c')
-rw-r--r--attr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/attr.c b/attr.c
index 3430faf2cc..887a9ae46b 100644
--- a/attr.c
+++ b/attr.c
@@ -353,7 +353,7 @@ static struct attr_stack *read_attr_from_file(const char *path, int macro_ok)
int lineno = 0;
if (!fp) {
- if (errno != ENOENT)
+ if (errno != ENOENT && errno != ENOTDIR)
warn_on_inaccessible(path);
return NULL;
}