diff options
author | Junio C Hamano <gitster@pobox.com> | 2014-12-12 23:31:33 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-12-12 23:31:33 +0100 |
commit | c09988ad940338eae5e2dbaa492bc4705ec5cb6a (patch) | |
tree | ff7e96e58958a313fef9190c12282ca9df744c5b /unpack-trees.c | |
parent | First batch for 2.3 cycle (diff) | |
parent | unpack_trees: plug leakage of o->result (diff) | |
download | git-c09988ad940338eae5e2dbaa492bc4705ec5cb6a.tar.xz git-c09988ad940338eae5e2dbaa492bc4705ec5cb6a.zip |
Merge branch 'jc/unpack-trees-plug-leak'
* jc/unpack-trees-plug-leak:
unpack_trees: plug leakage of o->result
Diffstat (limited to 'unpack-trees.c')
-rw-r--r-- | unpack-trees.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/unpack-trees.c b/unpack-trees.c index 629c658c46..3a66849e38 100644 --- a/unpack-trees.c +++ b/unpack-trees.c @@ -1155,6 +1155,8 @@ int unpack_trees(unsigned len, struct tree_desc *t, struct unpack_trees_options if (o->dst_index) { discard_index(o->dst_index); *o->dst_index = o->result; + } else { + discard_index(&o->result); } done: |