mirror of
https://github.com/git/git
synced 2024-08-24 18:26:02 +00:00
Merge branch 'mh/release-commit-memory-fix'
Leakfix. * mh/release-commit-memory-fix: commit: free the right buffer in release_commit_memory
This commit is contained in:
commit
21ce0b48f3
2
commit.c
2
commit.c
|
@ -364,8 +364,8 @@ struct object_id *get_commit_tree_oid(const struct commit *commit)
|
|||
void release_commit_memory(struct parsed_object_pool *pool, struct commit *c)
|
||||
{
|
||||
set_commit_tree(c, NULL);
|
||||
c->index = 0;
|
||||
free_commit_buffer(pool, c);
|
||||
c->index = 0;
|
||||
free_commit_list(c->parents);
|
||||
|
||||
c->object.parsed = 0;
|
||||
|
|
Loading…
Reference in a new issue