mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-03 12:11:33 +01:00
gpg: Improve an error message.
* g10/revoke.c (gen_revoke): Provide a more descriptive error message if searching for a key fails. -- Signed-off-by: Neal H. Walfield <neal@g10code.com> GnuPG-bug-id: 1987
This commit is contained in:
parent
6b14df5525
commit
46e128d44a
@ -614,8 +614,12 @@ gen_revoke (const char *uname)
|
|||||||
rc = keydb_search (kdbhd, &desc, 1, NULL);
|
rc = keydb_search (kdbhd, &desc, 1, NULL);
|
||||||
if (rc)
|
if (rc)
|
||||||
{
|
{
|
||||||
log_error (_("secret key \"%s\" not found: %s\n"),
|
if (gpg_err_code (rc) == GPG_ERR_NOT_FOUND)
|
||||||
uname, gpg_strerror (rc));
|
log_error (_("no secret key matches the search term \"%s\"\n"),
|
||||||
|
uname);
|
||||||
|
else
|
||||||
|
log_error (_("error looking up secret key \"%s\": %s\n"),
|
||||||
|
uname, gpg_strerror (rc));
|
||||||
goto leave;
|
goto leave;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user