From 60559a15e170ad49b388ee442eb2ccbe483bc9aa Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Mon, 19 Nov 2012 19:50:47 -0500 Subject: [PATCH] update: fix use after free mark the address space as unread so that we don't attempt a double free on a repo download failure during the final cleanup. --- src/update.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/update.c b/src/update.c index c2e76e5..0b4fb8a 100644 --- a/src/update.c +++ b/src/update.c @@ -552,7 +552,7 @@ static int add_repo_download(CURLM *multi, struct repo_t *repo) } else { curl_multi_remove_handle(multi, repo->curl); FREE(repo->url); - free(repo->data); + FREE(repo->data); repo->buflen = 0; repo->server_idx++; } -- 1.8.0