mirror of
git://git.gnupg.org/gnupg.git
synced 2025-02-02 16:43:03 +01:00
gpg: Don't crash if key is not passed an argument.
* g10/keyedit.c (menu_select_key): Don't crash if P is NULL. -- Signed-off-by: Neal H. Walfield <neal@g10code.com>
This commit is contained in:
parent
178af9c3f5
commit
19f099463c
@ -4892,8 +4892,9 @@ menu_select_key (KBNODE keyblock, int idx, char *p)
|
||||
{
|
||||
KBNODE node;
|
||||
int i, j;
|
||||
int is_hex_digits = strlen (p) >= 8;
|
||||
int is_hex_digits;
|
||||
|
||||
is_hex_digits = p && strlen (p) >= 8;
|
||||
if (is_hex_digits)
|
||||
{
|
||||
for (i = 0, j = 0; p[i]; i ++)
|
||||
|
Loading…
x
Reference in New Issue
Block a user