From c8f95f324b9176ecd8b3d2645553c527c99d17a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6nke=20Ludwig?= Date: Thu, 22 Feb 2018 01:12:13 +0100 Subject: [PATCH] Enable canceling win32 file I/O. The CancelIOEx call was disabled just due to historical reasons. --- source/eventcore/drivers/winapi/files.d | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/eventcore/drivers/winapi/files.d b/source/eventcore/drivers/winapi/files.d index b5900e6..6ba6159 100644 --- a/source/eventcore/drivers/winapi/files.d +++ b/source/eventcore/drivers/winapi/files.d @@ -8,7 +8,6 @@ import eventcore.internal.win32; private extern(Windows) @trusted nothrow @nogc { BOOL SetEndOfFile(HANDLE hFile); - BOOL CancelIoEx(HANDLE hFile, OVERLAPPED* lpOverlapped); } final class WinAPIEventDriverFiles : EventDriverFiles { @@ -170,7 +169,7 @@ final class WinAPIEventDriverFiles : EventDriverFiles { { if (slot.callback) { m_core.removeWaiter(); - //CancelIoEx(h, &slot.overlapped); // FIXME: currently causes linker errors for DMD due to outdated kernel32.lib files + () @trusted { CancelIoEx(h, &slot.overlapped); } (); slot.callback = null; slot.buffer = null; }