mirror of
https://github.com/git/git.git
synced 2024-10-28 12:59:41 +01:00
git_config: access() returns 0 on success, not > 0
Another late-night bug. Sorry again. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
parent
92a28be0ce
commit
e33d0611c0
1 changed files with 1 additions and 1 deletions
2
config.c
2
config.c
|
@ -335,7 +335,7 @@ int git_config(config_fn_t fn)
|
|||
|
||||
if (home) {
|
||||
char *user_config = strdup(mkpath("%s/.gitconfig", home));
|
||||
if (access(user_config, R_OK) > 0)
|
||||
if (!access(user_config, R_OK))
|
||||
ret = git_config_from_file(fn, user_config);
|
||||
free(user_config);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue