w32: Fix deadlock introduced by keybox_file_rename.
authorWerner Koch <wk@gnupg.org>
Thu, 14 Jan 2016 19:45:33 +0000 (20:45 +0100)
committerWerner Koch <wk@gnupg.org>
Thu, 14 Jan 2016 19:45:33 +0000 (20:45 +0100)
commit663c5d129a8f400cc6eb8ab7b91772d6e578152d
tree43026236515008a27c4ec854c1630050a0d15e43
parent3b1248e007a6bf830a3230ee2d9cc548205ec31a
w32: Fix deadlock introduced by keybox_file_rename.

* g10/keyring.c (keyring_lock) [W32]: Flush the close cache before
locking.
* kbx/keybox-init.c (keybox_lock) [W32]: Close the file before
locking.

Signed-off-by: Werner Koch <wk@gnupg.org>
g10/keyring.c
kbx/keybox-init.c