checkout: fix memory leak

Discovered via Coverity.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
Johannes Schindelin
2017-04-18 14:02:51 +02:00
parent 1877204af5
commit 6eb8559847

View File

@@ -232,6 +232,7 @@ static int checkout_merged(int pos, const struct checkout *state)
if (!ce)
die(_("make_cache_entry failed for path '%s'"), path);
status = checkout_entry(ce, state, NULL);
free(ce);
return status;
}