diff --git a/builtin-update-index.c b/builtin-update-index.c
index a3c0a455ae5d1b8d7b7b6a8798ed7f038ab7bd72..7f9c638466f79fee7d2914b8ec76d713c3670e7e 100644 (file)
--- a/builtin-update-index.c
+++ b/builtin-update-index.c
static void read_head_pointers(void)
{
- if (read_ref(git_path("HEAD"), head_sha1))
+ if (read_ref("HEAD", head_sha1))
die("No HEAD -- no initial commit yet?\n");
- if (read_ref(git_path("MERGE_HEAD"), merge_head_sha1)) {
+ if (read_ref("MERGE_HEAD", merge_head_sha1)) {
fprintf(stderr, "Not in the middle of a merge.\n");
exit(0);
}
int has_head = 1;
const char **pathspec = get_pathspec(prefix, av + 1);
- if (read_ref(git_path("HEAD"), head_sha1))
+ if (read_ref("HEAD", head_sha1))
/* If there is no HEAD, that means it is an initial
* commit. Update everything in the index.
*/