commit a0ed7e3b9fa6312b18accef0c0ab5a084e3c2d8d
parent 1cfe78b4d78fa274e90598a2a8b48bc2ea724a16
Author: Andrej Kacian <ticho@claws-mail.org>
Date: Mon, 8 Oct 2018 13:29:21 +0200
Added some NULL checks in passwordstore.c to avoid potential crash.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/passwordstore.c b/src/passwordstore.c
@@ -307,7 +307,7 @@ void passwd_store_reencrypt_all(const gchar *old_mpwd,
debug_print("Reencrypting passwords in block (%d/%s).\n",
block->block_type, block->block_name);
- if (g_hash_table_size(block->entries) == 0)
+ if (block->entries == NULL || g_hash_table_size(block->entries) == 0)
continue;
keys = g_hash_table_get_keys(block->entries);