From 7038d0048979db61ec75be51e2e62ac34a297176 Mon Sep 17 00:00:00 2001 From: Steve Lhomme Date: Sat, 21 Apr 2018 11:00:03 +0200 Subject: [PATCH] fix build with gcc 7 --- src/platform/win32/WinIOCallback.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/platform/win32/WinIOCallback.cpp b/src/platform/win32/WinIOCallback.cpp index b1310ee..f3aeff4 100644 --- a/src/platform/win32/WinIOCallback.cpp +++ b/src/platform/win32/WinIOCallback.cpp @@ -95,7 +95,7 @@ bool WinIOCallback::open(const char* Path, const open_mode aMode, DWORD dwFlags) } mFile = CreateFileA(Path, AccessMode, ShareMode, NULL, Disposition, dwFlags, NULL); - if ((mFile == INVALID_HANDLE_VALUE) || ((long)mFile == 0xffffffff)) { + if ((mFile == INVALID_HANDLE_VALUE) || (mFile == (HANDLE)0xffffffff)) { //File was not opened char err_msg[256]; DWORD error_code = GetLastError(); @@ -177,7 +177,7 @@ bool WinIOCallback::open(const wchar_t* Path, const open_mode aMode, DWORD dwFla return mOk = false; } } - if ((mFile == INVALID_HANDLE_VALUE) || ((long)mFile == 0xffffffff)) { + if ((mFile == INVALID_HANDLE_VALUE) || (mFile == (HANDLE)0xffffffff)) { //File was not opened char err_msg[256]; DWORD error_code = GetLastError(); -- 2.8.1.windows.1