From 9b4aabdb0f0906f9cc2f38954d048d5e917db093 Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Fri, 3 Nov 2006 03:56:02 +0000 Subject: * Modified some error output and logging * Changed the initial log mask (added PM_LOG_ERROR) * Fixed -Syu so it now works if any databases were downloaded (it was working like a -Su) --- lib/libalpm/error.h | 2 +- lib/libalpm/server.c | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'lib/libalpm') diff --git a/lib/libalpm/error.h b/lib/libalpm/error.h index bee36076..5f53712a 100644 --- a/lib/libalpm/error.h +++ b/lib/libalpm/error.h @@ -22,7 +22,7 @@ #define _ALPM_ERROR_H #define RET_ERR(err, ret) do { pm_errno = (err); \ - _alpm_log(PM_LOG_ERROR, _("returning error %d: %s\n"), err, alpm_strerror(err)); \ + _alpm_log(PM_LOG_DEBUG, _("returning error %d: %s\n"), err, alpm_strerror(err)); \ return(ret); } while(0) #endif /* _ALPM_ERROR_H */ diff --git a/lib/libalpm/server.c b/lib/libalpm/server.c index 420b4a2e..35905489 100644 --- a/lib/libalpm/server.c +++ b/lib/libalpm/server.c @@ -181,9 +181,8 @@ int _alpm_downloadfiles_forreal(pmlist_t *servers, const char *localpath, dlf = fetchXGet(server->s_url, &ust, (handle->nopassiveftp ? "" : "p")); } if(fetchLastErrCode != 0 || dlf == NULL) { - _alpm_log(PM_LOG_ERROR, _("failed retrieving file '%s' from '%s://%s%s', %d : %s"), fn, - server->s_url->scheme, server->s_url->host, server->s_url->doc, fetchLastErrCode, - fetchLastErrString); + _alpm_log(PM_LOG_ERROR, _("failed retrieving file '%s' from %s://%s: %s"), fn, + server->s_url->scheme, server->s_url->host, fetchLastErrString); if(localf != NULL) { fclose(localf); } -- cgit v1.2.3-70-g09d2