Skip to content

Commit

Permalink
mingw: Suppress warning that <commit>:.gitattributes does not exist
Browse files Browse the repository at this point in the history
On Windows, a file name containing a colon is illegal. We should
therefore expect the corresponding errno when `fopen()` is called for a
path of the form <commit>:.gitattributes.

This fixes #255.

Signed-off-by: Johannes Schindelin <[email protected]>
  • Loading branch information
dscho committed Oct 4, 2015
1 parent 434f0b2 commit 596f184
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion attr.c
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ static struct attr_stack *read_attr_from_file(const char *path, int macro_ok)
int lineno = 0;

if (!fp) {
if (errno != ENOENT && errno != ENOTDIR)
if (errno != ENOENT && errno != ENOTDIR && errno != EINVAL)
warn_on_inaccessible(path);
return NULL;
}
Expand Down

0 comments on commit 596f184

Please sign in to comment.