static void print_line(struct strbuf *buf)
{
strbuf_addch(buf, '\n');
- write_or_die(credential_lock.fd, buf->buf, buf->len);
+ write_or_die(get_lock_file_fd(&credential_lock), buf->buf, buf->len);
}
static void rewrite_credential_file(const char *fn, struct credential *c,
} else {
if ((file = expand_user_path("~/.git-credentials")))
string_list_append_nodup(&fns, file);
- home_config_paths(NULL, &file, "credentials");
+ file = xdg_config_home("credentials");
if (file)
string_list_append_nodup(&fns, file);
}