diff options
| author | Joseph Hunkeler <jhunkeler@gmail.com> | 2026-02-12 09:53:21 -0500 |
|---|---|---|
| committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2026-02-12 09:53:21 -0500 |
| commit | 2cd2d2c47593941f002ed45f44f0e0c1072738d7 (patch) | |
| tree | 4889f9b9b2767456d0375dd5a262259ad732f8c6 | |
| parent | 4458f2e9da2ef474c63457a96ee0f637fa89ad14 (diff) | |
| download | stasis-retry-download.tar.gz | |
errmsg argument must be a valid pointerretry-download
* Remove redundant status check already performed by HTTP_ERROR()
| -rw-r--r-- | src/lib/core/artifactory.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/core/artifactory.c b/src/lib/core/artifactory.c index eedaf43..d5457e7 100644 --- a/src/lib/core/artifactory.c +++ b/src/lib/core/artifactory.c @@ -61,9 +61,10 @@ int artifactory_download_cli(char *dest, } sprintf(path + strlen(path), "/%s", remote_filename); - long fetch_status = download(url, path, NULL); - if (HTTP_ERROR(fetch_status) || fetch_status < 0) { - fprintf(stderr, "%s: download failed: %s\n", __FUNCTION__, url); + char *errmsg = NULL; + long fetch_status = download(url, path, &errmsg); + if (HTTP_ERROR(fetch_status)) { + SYSERROR("download failed: %s: %s\n", errmsg, url); return -1; } chmod(path, 0755); |
