Show an error message on failed remote key lookup

The absolutely terrible part about this is the failure on GPGME's part
to distinguish between "key not found" and "keyserver timeout". Instead,
it returns the same silly GPG_ERR_EOF in both cases (why isn't
GPG_ERR_TIMEOUT being used?), leaving us helpless to tell them apart.

Spit out a generic enough error message that covers both cases;
unfortunately we can't provide much guidance to the user because we
aren't sure what actually happened.

Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Dan McGee 2011-10-17 09:38:35 -05:00
parent 842c4422ed
commit bac670ddc9

View File

@ -797,8 +797,8 @@ int _alpm_process_siglist(alpm_handle_t *handle, const char *identifier,
fetch_key.fingerprint, fetch_key.uid);
}
} else {
_alpm_log(handle, ALPM_LOG_DEBUG,
"key could not be looked up remotely\n");
_alpm_log(handle, ALPM_LOG_ERROR,
_("key \"%s\" could not be looked up remotely\n"), name);
}
gpgme_key_unref(fetch_key.data);
}