Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/commit.c')
-rw-r--r--builtin/commit.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index 795f9d24f2..6aac5e284c 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -299,7 +299,7 @@ static void create_base_index(const struct commit *current_head)
opts.dst_index = &the_index;
opts.fn = oneway_merge;
- tree = parse_tree_indirect(get_object_hash(current_head->object));
+ tree = parse_tree_indirect(current_head->object.oid.hash);
if (!tree)
die(_("failed to unpack HEAD tree object"));
parse_tree(tree);
@@ -1766,7 +1766,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
if (!transaction ||
ref_transaction_update(transaction, "HEAD", sha1,
current_head
- ? get_object_hash(current_head->object) : null_sha1,
+ ? current_head->object.oid.hash : null_sha1,
0, sb.buf, &err) ||
ref_transaction_commit(transaction, &err)) {
rollback_index_files();
@@ -1793,10 +1793,10 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
cfg = init_copy_notes_for_rewrite("amend");
if (cfg) {
/* we are amending, so current_head is not NULL */
- copy_note_for_rewrite(cfg, get_object_hash(current_head->object), sha1);
+ copy_note_for_rewrite(cfg, current_head->object.oid.hash, sha1);
finish_copy_notes_for_rewrite(cfg, "Notes added by 'git commit --amend'");
}
- run_rewrite_hook(get_object_hash(current_head->object), sha1);
+ run_rewrite_hook(current_head->object.oid.hash, sha1);
}
if (!quiet)
print_summary(prefix, sha1, !current_head);