]> git.ipfire.org Git - thirdparty/git.git/blobdiff - builtin/var.c
Merge branch 'vd/fsck-submodule-url-test'
[thirdparty/git.git] / builtin / var.c
index 74161bdf1c61b5248150bac284898e3c03c79111..cf5567208a277a62b872a1846919060fb6e276c3 100644 (file)
@@ -66,7 +66,7 @@ static char *git_attr_val_system(int ident_flag UNUSED)
 
 static char *git_attr_val_global(int ident_flag UNUSED)
 {
-       char *file = xstrdup(git_attr_global_file());
+       char *file = xstrdup_or_null(git_attr_global_file());
        if (file) {
                normalize_path_copy(file, file);
                return file;
@@ -90,7 +90,7 @@ static char *git_config_val_global(int ident_flag UNUSED)
        char *user, *xdg;
        size_t unused;
 
-       git_global_config(&user, &xdg);
+       git_global_config_paths(&user, &xdg);
        if (xdg && *xdg) {
                normalize_path_copy(xdg, xdg);
                strbuf_addf(&buf, "%s\n", xdg);