summaryrefslogtreecommitdiffstats
path: root/dirmngr
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2022-03-24 05:55:32 +0100
committerNIIBE Yutaka <gniibe@fsij.org>2022-03-24 05:55:32 +0100
commit4d19759ce5fb4962b22a8bc04c3a54e3f47d2f17 (patch)
tree127131cdb7bb4338107127f163118d61b99a8d51 /dirmngr
parentkbx: Fix searching for FPR20 in version 2 blob. (diff)
downloadgnupg2-4d19759ce5fb4962b22a8bc04c3a54e3f47d2f17.tar.xz
gnupg2-4d19759ce5fb4962b22a8bc04c3a54e3f47d2f17.zip
dirmngr: Clear the error count to try certificate as binary.
* dirmngr/dirmngr-client.c (read_certificate): Call log_get_errorcount. -- GnuPG-bug-id: 5531 Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'dirmngr')
-rw-r--r--dirmngr/dirmngr-client.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/dirmngr/dirmngr-client.c b/dirmngr/dirmngr-client.c
index 1560fd30e..67052c92e 100644
--- a/dirmngr/dirmngr-client.c
+++ b/dirmngr/dirmngr-client.c
@@ -634,6 +634,8 @@ read_certificate (const char *fname, unsigned char **rbuf, size_t *rbuflen)
err = read_pem_certificate (fname, rbuf, rbuflen);
if (! err)
return 0;
+ /* Clear the error count to try as binary certificate. */
+ log_get_errorcount (1);
}
fp = fname? es_fopen (fname, "rb") : es_stdin;