1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00

agent: Fix possible uninitalized use of CTX in simple_pwquery.

* common/simple-pwquery.c (agent_open): Clear CTX even on early error.
--

GnuPG-bug-id: 4223
Signed-off-by: Werner Koch <wk@gnupg.org>
(cherry picked from commit bafcf7095159493a656382997f8b0d0bb11a20e8)
This commit is contained in:
Werner Koch 2018-10-24 20:22:17 +02:00
parent 62c7527117
commit e53253485c
No known key found for this signature in database
GPG Key ID: E3FDFF218E45B72B

View File

@ -246,6 +246,7 @@ agent_open (assuan_context_t *ctx)
#ifdef SPWQ_USE_LOGGING #ifdef SPWQ_USE_LOGGING
log_error (_("no gpg-agent running in this session\n")); log_error (_("no gpg-agent running in this session\n"));
#endif #endif
*ctx = NULL;
return SPWQ_NO_AGENT; return SPWQ_NO_AGENT;
} }