From c687f56ad491313748697bf6f94998240738fc21 Mon Sep 17 00:00:00 2001 From: Ikey Doherty Date: Mon, 18 Apr 2016 02:28:20 +0100 Subject: [PATCH] fetch: Follow HTTP redirects due to recent NVD issue Now this is the last change on this branch.. Work will now be happening on the `2` branch to clean everything up. Signed-off-by: Ikey Doherty --- src/library/fetch.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/library/fetch.c b/src/library/fetch.c index c9146e6..06d4b30 100644 --- a/src/library/fetch.c +++ b/src/library/fetch.c @@ -82,6 +82,11 @@ FetchStatus fetch_uri(const char *uri, const char *target, bool verbose) goto bail; } + /* Handle future redirects from NVD */ + res = curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L); + if (res != CURLE_OK) { + goto bail; + } res = curl_easy_perform(curl); if (res != CURLE_OK) { goto bail;