Commit 492cb39
midx.c: don't leak MIDX from verify_midx_file
The function midx.c:verify_midx_file() allocates a MIDX struct by
calling load_multi_pack_index(). But when cleaning up, it calls free()
without freeing any resources associated with the MIDX.
Call the more appropriate close_midx() which does free those resources,
which causes t5319.3 to pass when Git is compiled with SANITIZE=leak.
Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>1 parent 692305e commit 492cb39
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1603 | 1603 | | |
1604 | 1604 | | |
1605 | 1605 | | |
1606 | | - | |
| 1606 | + | |
1607 | 1607 | | |
1608 | 1608 | | |
1609 | 1609 | | |
| |||
1681 | 1681 | | |
1682 | 1682 | | |
1683 | 1683 | | |
| 1684 | + | |
1684 | 1685 | | |
| 1686 | + | |
1685 | 1687 | | |
1686 | 1688 | | |
1687 | 1689 | | |
| |||
0 commit comments