aboutsummaryrefslogtreecommitdiff
path: root/src/artifactory.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/artifactory.c')
-rw-r--r--src/artifactory.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/artifactory.c b/src/artifactory.c
index 8cc0db5..437912d 100644
--- a/src/artifactory.c
+++ b/src/artifactory.c
@@ -59,7 +59,8 @@ int artifactory_download_cli(char *dest,
}
sprintf(path + strlen(path), "/%s", remote_filename);
- if (HTTP_ERROR(download(url, path, NULL))) {
+ long fetch_status = download(url, path, NULL);
+ if (HTTP_ERROR(fetch_status) || fetch_status < 0) {
fprintf(stderr, "%s: download failed: %s\n", __FUNCTION__, url);
return -1;
}