Skip to content

Commit 8057648

Browse files
dschoGit for Windows Build Agent
authored and
Git for Windows Build Agent
committed
Merge pull request #2370 from dscho/prettify-etc-gitconfig-path
config: normalize the path of the system gitconfig
2 parents 0612134 + daeb7b8 commit 8057648

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

config.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1657,9 +1657,11 @@ static int git_config_from_blob_ref(config_fn_t fn,
16571657

16581658
const char *git_etc_gitconfig(void)
16591659
{
1660-
static const char *system_wide;
1661-
if (!system_wide)
1660+
static char *system_wide;
1661+
if (!system_wide) {
16621662
system_wide = system_path(ETC_GITCONFIG);
1663+
normalize_path_copy(system_wide, system_wide);
1664+
}
16631665
return system_wide;
16641666
}
16651667

0 commit comments

Comments
 (0)