From d24c5df52b55e86b49b48f153a1ada5a5081eda5 Mon Sep 17 00:00:00 2001 From: Jakub Jelen Date: Mon, 13 Sep 2021 19:04:56 +0200 Subject: [PATCH] gpg: Avoid uninitialized revkey.fprlen. * g10/keygen.c (parse_revocation_key): Store the fingerprint length in created structure. -- GnuPG-bug-id: 5393 Signed-off-by: Jakub Jelen --- g10/keygen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/g10/keygen.c b/g10/keygen.c index cb6487ea3..7f15027a2 100644 --- a/g10/keygen.c +++ b/g10/keygen.c @@ -4003,6 +4003,8 @@ parse_revocation_key (const char *fname, if (i != 20 && i != 32) goto fail; + revkey.fprlen = i; + /* skip to the tag */ while(*pn && *pn!='s' && *pn!='S') pn++;