mirror of
https://git.proxmox.com/git/libgit2
synced 2025-08-12 12:00:29 +00:00
Fix a memory leak in git_pathspec__vinit
.
This commit is contained in:
parent
be29dd82e2
commit
63170bcae9
@ -89,8 +89,10 @@ int git_pathspec__vinit(
|
|||||||
if (ret == GIT_ENOTFOUND) {
|
if (ret == GIT_ENOTFOUND) {
|
||||||
git__free(match);
|
git__free(match);
|
||||||
continue;
|
continue;
|
||||||
} else if (ret < 0)
|
} else if (ret < 0) {
|
||||||
|
git__free(match);
|
||||||
return ret;
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
if (git_vector_insert(vspec, match) < 0)
|
if (git_vector_insert(vspec, match) < 0)
|
||||||
return -1;
|
return -1;
|
||||||
|
Loading…
Reference in New Issue
Block a user