From 061948597dd0fc4fda4197b7bfca6f730c43b9c8 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Sun, 7 Dec 2008 13:20:25 -0600 Subject: Add some error codes for signature verification Signed-off-by: Dan McGee --- lib/libalpm/alpm.h | 3 +++ lib/libalpm/error.c | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h index faba1330..1c8d232e 100644 --- a/lib/libalpm/alpm.h +++ b/lib/libalpm/alpm.h @@ -526,6 +526,9 @@ enum _pmerrno_t { PM_ERR_PKG_INVALID_NAME, PM_ERR_PKG_INVALID_ARCH, PM_ERR_PKG_REPO_NOT_FOUND, + /* Signatures */ + PM_ERR_SIG_INVALID, + PM_ERR_SIG_UNKNOWN, /* Deltas */ PM_ERR_DLT_INVALID, PM_ERR_DLT_PATCHFAILED, diff --git a/lib/libalpm/error.c b/lib/libalpm/error.c index dcf26074..71c058f6 100644 --- a/lib/libalpm/error.c +++ b/lib/libalpm/error.c @@ -115,6 +115,11 @@ const char SYMEXPORT *alpm_strerror(int err) return _("package architecture is not valid"); case PM_ERR_PKG_REPO_NOT_FOUND: return _("could not find repository for target"); + /* Signatures */ + case PM_ERR_SIG_INVALID: + return _("invalid PGP signature"); + case PM_ERR_SIG_UNKNOWN: + return _("unknown PGP signature"); /* Deltas */ case PM_ERR_DLT_INVALID: return _("invalid or corrupted delta"); -- cgit v1.2.3-70-g09d2