mirror of
https://github.com/moparisthebest/pacman
synced 2024-12-23 08:18:51 -05:00
signing: add more detail to unexpected signature count error
Do a quick loop and count of the returned data so we can show how many signatures were parsed and read. Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
parent
1d7ad5d24b
commit
b7b3fc2386
@ -293,7 +293,13 @@ int _alpm_gpgme_checksig(const char *path, const char *base64_sig)
|
|||||||
result = gpgme_op_verify_result(ctx);
|
result = gpgme_op_verify_result(ctx);
|
||||||
gpgsig = result->signatures;
|
gpgsig = result->signatures;
|
||||||
if(!gpgsig || gpgsig->next) {
|
if(!gpgsig || gpgsig->next) {
|
||||||
_alpm_log(PM_LOG_ERROR, _("Unexpected number of signatures\n"));
|
int count = 0;
|
||||||
|
while(gpgsig) {
|
||||||
|
count++;
|
||||||
|
gpgsig = gpgsig->next;
|
||||||
|
}
|
||||||
|
_alpm_log(PM_LOG_ERROR, _("Unexpected number of signatures (%d)\n"),
|
||||||
|
count);
|
||||||
ret = -1;
|
ret = -1;
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user