Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'ma/reduce-heads-leakfix' into maint
author
Junio C Hamano
<gitster@pobox.com>
Mon, 27 Nov 2017 01:57:02 +0000
(10:57 +0900)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 27 Nov 2017 01:57:02 +0000
(10:57 +0900)
Leak fixes.
* ma/reduce-heads-leakfix:
reduce_heads: fix memory leaks
builtin/merge-base: free commit lists
1
2
builtin/commit.c
patch
|
diff1
|
diff2
|
blob
|
history
raw
|
compact
(merge:
03e8004
4da7264
)
diff --combined
builtin/commit.c
index b2a6c7f100d82c4160c4bea6b4663af5459194cc,11c47401854fa4bfd8b75429f053882ff1c61551..be370f64a995804ec6b62e03f7c6940044e08e24
---
1
/
builtin/commit.c
---
2
/
builtin/commit.c
+++ b/
builtin/commit.c
@@@
-1492,8
-1492,6
+1492,8
@@@
static void print_summary(const char *p
diff_setup_done(&rev.diffopt);
head = resolve_ref_unsafe("HEAD", 0, NULL, NULL);
+ if (!head)
+ die_errno(_("unable to resolve HEAD after creating commit"));
if (!strcmp(head, "HEAD"))
head = _("detached HEAD");
else
@@@
-1730,7
-1728,7
+1730,7
@@@
int cmd_commit(int argc, const char **a
allow_fast_forward = 0;
}
if (allow_fast_forward)
-
parents = reduce_heads(
parents);
+
reduce_heads_replace(&
parents);
} else {
if (!reflog_msg)
reflog_msg = (whence == FROM_CHERRY_PICK)