kbx: Fix an endless loop under Windows due to an incomplete fix.
authorWerner Koch <wk@gnupg.org>
Thu, 16 May 2019 11:57:04 +0000 (13:57 +0200)
committerWerner Koch <wk@gnupg.org>
Thu, 16 May 2019 11:57:04 +0000 (13:57 +0200)
commit6fc5df1e10129f3171d80cf731f310b9e8d97c26
tree9d60610bc0324a2aca86f9871b5106faa562ccba
parent50c2f76ae65d4ee793876865011fa97c85f38ac2
kbx: Fix an endless loop under Windows due to an incomplete fix.

* kbx/keybox-search.c (keybox_search):  We need to seek to the last
position in all cases not just when doing a NEXT.
--

This is because search from the beginning needs a keybox_search_reset.
We can only make an exception for KEYDB_SEARCH_MODE_FIRST..

Fixes-commit: 49b236af0ecbb6df67513feb4b63851f2e159ea2
Signed-off-by: Werner Koch <wk@gnupg.org>
kbx/keybox-search.c