aboutsummaryrefslogtreecommitdiffstats
path: root/agent/findkey.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2010-06-17 15:44:44 +0000
committerWerner Koch <[email protected]>2010-06-17 15:44:44 +0000
commit006fd75aea5cc766bc223e435e5a07b543d658d3 (patch)
tree2f4365e73bf0a8b5272426fcf1fde9b75be4002e /agent/findkey.c
parentAdd makefiles to build a w32 development package. (diff)
downloadgnupg-006fd75aea5cc766bc223e435e5a07b543d658d3.tar.gz
gnupg-006fd75aea5cc766bc223e435e5a07b543d658d3.zip
Avoid using the protect-tool to import pkcs#12.
Diffstat (limited to 'agent/findkey.c')
-rw-r--r--agent/findkey.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/agent/findkey.c b/agent/findkey.c
index d6478ac4d..db610c15a 100644
--- a/agent/findkey.c
+++ b/agent/findkey.c
@@ -69,7 +69,7 @@ agent_write_private_key (const unsigned char *grip,
{
log_error ("secret key file `%s' already exists\n", fname);
xfree (fname);
- return gpg_error (GPG_ERR_GENERAL);
+ return gpg_error (GPG_ERR_EEXIST);
}
/* FIXME: On POSIX systems we used include S_IRGRP as well. */
@@ -883,8 +883,8 @@ agent_public_key_from_file (ctrl_t ctrl,
-/* Return the secret key as an S-Exp after locating it using the grip.
- Returns NULL if key is not available. 0 = key is available */
+/* Check whether the the secret key identified by GRIP is available.
+ Returns 0 is the key is available. */
int
agent_key_available (const unsigned char *grip)
{