Fix calling CancelSynchronousIo.

* src/w32-util.c (_gpgme_w32_cancel_synchronous_io): Use HANDLE.

--

GnuPG-bug-id: 6634
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2024-07-05 13:52:33 +09:00
parent de60684500
commit 95bd4fa813
No known key found for this signature in database
GPG Key ID: 640114AF89DE6054

View File

@ -297,7 +297,7 @@ void
_gpgme_w32_cancel_synchronous_io (HANDLE thread) _gpgme_w32_cancel_synchronous_io (HANDLE thread)
{ {
static int initialized; static int initialized;
static BOOL (WINAPI * func)(DWORD); static BOOL (WINAPI * func)(HANDLE);
void *handle; void *handle;
if (!initialized) if (!initialized)
@ -318,7 +318,7 @@ _gpgme_w32_cancel_synchronous_io (HANDLE thread)
if (func) if (func)
{ {
if (!func ((DWORD)thread) && GetLastError() != ERROR_NOT_FOUND) if (!func (thread) && GetLastError() != ERROR_NOT_FOUND)
{ {
TRACE (DEBUG_ENGINE, "gpgme:CancelSynchronousIo", NULL, TRACE (DEBUG_ENGINE, "gpgme:CancelSynchronousIo", NULL,
"called for thread %p: ec=%u", "called for thread %p: ec=%u",