tree-cache: Free the tree upon the detection of a corrupted child

This commit is contained in:
nulltoken 2013-11-19 12:54:57 +01:00
parent e1ce5249e5
commit 7b69289f4e

View File

@ -140,7 +140,7 @@ static int read_tree_internal(git_tree_cache **out,
for (i = 0; i < tree->children_count; ++i) {
if (read_tree_internal(&tree->children[i], &buffer, buffer_end, tree) < 0)
return -1;
goto corrupted;
}
}