Commit 76911fd28aa2313e62eb8f866862047c4befc10d

Stefan Sperling 2020-03-19T23:02:36

allow 'got fetch' to operate on a non-bare git repository

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/lib/fetch.c b/lib/fetch.c
index 0fa6534..132da7a 100644
--- a/lib/fetch.c
+++ b/lib/fetch.c
@@ -400,7 +400,7 @@ got_fetch_pack(struct got_object_id **pack_hash, struct got_pathlist_head *refs,
 	pid_t fetchpid, idxpid;
 	char *tmppackpath = NULL, *tmpidxpath = NULL;
 	char *packpath = NULL, *idxpath = NULL, *id_str = NULL;
-	const char *repo_path = got_repo_get_path(repo);
+	const char *repo_path = got_repo_get_path_git_dir(repo);
 	struct got_pathlist_head have_refs;
 	struct got_pathlist_entry *pe;
 	struct got_reflist_head my_refs;