summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Martín Nieto <cmn@dwim.me>2015-05-04 09:39:55 +0200
committerCarlos Martín Nieto <cmn@dwim.me>2015-05-13 09:46:57 +0200
commit3251972e1fbab379d9ec5a94e455431d005446d1 (patch)
tree5ae893bcb3220ccdab9284c271a966b20946a1a5
parentb1ae3e5317239db70670a13fd751a4442289e128 (diff)
downloadlibgit2-3251972e1fbab379d9ec5a94e455431d005446d1.tar.gz
push: free the update list
-rw-r--r--src/push.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/push.c b/src/push.c
index cd219e905..abe90b76d 100644
--- a/src/push.c
+++ b/src/push.c
@@ -682,6 +682,7 @@ void git_push_free(git_push *push)
{
push_spec *spec;
push_status *status;
+ git_push_update *update;
unsigned int i;
if (push == NULL)
@@ -697,6 +698,13 @@ void git_push_free(git_push *push)
}
git_vector_free(&push->status);
+ git_vector_foreach(&push->updates, i, update) {
+ git__free(update->src_refname);
+ git__free(update->dst_refname);
+ git__free(update);
+ }
+ git_vector_free(&push->updates);
+
git__free(push);
}