mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
gpg: Fix keyring support.
* g10/keydb.c (keydb_rebuild_caches): Only mark the cached as prepared if it is actually prepared, which it only is if the resource is a keybox. -- Signed-off-by: Neal H. Walfield <neal@g10code.com>
This commit is contained in:
parent
421827424f
commit
99c84b49b7
@ -1701,7 +1701,8 @@ keydb_search (KEYDB_HANDLE hd, KEYDB_SEARCH_DESC *desc,
|
||||
if (!hd->no_caching
|
||||
&& !rc
|
||||
&& ndesc == 1 && (desc[0].mode == KEYDB_SEARCH_MODE_FPR20
|
||||
|| desc[0].mode == KEYDB_SEARCH_MODE_FPR))
|
||||
|| desc[0].mode == KEYDB_SEARCH_MODE_FPR)
|
||||
&& hd->active[hd->current].type == KEYDB_RESOURCE_TYPE_KEYBOX)
|
||||
{
|
||||
hd->keyblock_cache.state = KEYBLOCK_CACHE_PREPARED;
|
||||
memcpy (hd->keyblock_cache.fpr, desc[0].u.fpr, 20);
|
||||
|
Loading…
x
Reference in New Issue
Block a user