aboutsummaryrefslogtreecommitdiffstats
path: root/g10/call-agent.c
diff options
context:
space:
mode:
Diffstat (limited to 'g10/call-agent.c')
-rw-r--r--g10/call-agent.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/g10/call-agent.c b/g10/call-agent.c
index abd6eb34d..4a8a463b6 100644
--- a/g10/call-agent.c
+++ b/g10/call-agent.c
@@ -1783,8 +1783,8 @@ agent_get_s2k_count (unsigned long *r_count)
/* Ask the agent whether a secret key for the given public key is
- available. Returns 0 if available. */
-gpg_error_t
+ available. Returns 0 if not available. */
+int
agent_probe_secret_key (ctrl_t ctrl, PKT_public_key *pk)
{
gpg_error_t err;
@@ -1803,7 +1803,9 @@ agent_probe_secret_key (ctrl_t ctrl, PKT_public_key *pk)
xfree (hexgrip);
err = assuan_transact (agent_ctx, line, NULL, NULL, NULL, NULL, NULL, NULL);
- return err;
+ if (err)
+ return 0;
+ return 1;
}
/* Ask the agent whether a secret key is available for any of the