From 3c7d6a1769ed6cc90d86247a814a0dce341512a3 Mon Sep 17 00:00:00 2001 From: Justus Winter Date: Fri, 16 Dec 2016 15:50:17 +0100 Subject: sm: Fix agent communication. * sm/call-agent.c (gpgsm_agent_pksign): Fix passing the control handle to the callback. (gpgsm_scd_pksign): Likewise. (gpgsm_agent_reaedkey): Likewise. GnuPG-bug-id: 2874 Signed-off-by: Justus Winter --- sm/call-agent.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sm/call-agent.c b/sm/call-agent.c index 11e6ae769..16a2497c6 100644 --- a/sm/call-agent.c +++ b/sm/call-agent.c @@ -234,6 +234,7 @@ gpgsm_agent_pksign (ctrl_t ctrl, const char *keygrip, const char *desc, rc = start_agent (ctrl); if (rc) return rc; + inq_parm.ctrl = ctrl; inq_parm.ctx = agent_ctx; if (digestlen*2 + 50 > DIM(line)) @@ -319,6 +320,7 @@ gpgsm_scd_pksign (ctrl_t ctrl, const char *keyid, const char *desc, rc = start_agent (ctrl); if (rc) return rc; + inq_parm.ctrl = ctrl; inq_parm.ctx = agent_ctx; if (digestlen*2 + 50 > DIM(line)) @@ -583,6 +585,7 @@ gpgsm_agent_readkey (ctrl_t ctrl, int fromcard, const char *hexkeygrip, rc = start_agent (ctrl); if (rc) return rc; + inq_parm.ctrl = ctrl; inq_parm.ctx = agent_ctx; rc = assuan_transact (agent_ctx, "RESET",NULL, NULL, NULL, NULL, NULL, NULL); -- cgit v1.2.3