From 571e11cd42d30f8e851abd5697ed281189c9a295 Mon Sep 17 00:00:00 2001 From: Evil Eye Date: Wed, 1 Feb 2023 16:36:37 +0100 Subject: [PATCH] Restore 0936d716d96cd45b3efc2d1a3697614f7f96952d --- components/platform/file.win32.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/platform/file.win32.cpp b/components/platform/file.win32.cpp index 639a7f3643..efcb233fc0 100644 --- a/components/platform/file.win32.cpp +++ b/components/platform/file.win32.cpp @@ -51,8 +51,9 @@ namespace Platform::File const auto nativeHandle = getNativeHandle(handle); const auto nativeSeekType = getNativeSeekType(type); - if (SetFilePointer(nativeHandle, static_cast(position), nullptr, nativeSeekType) - == INVALID_SET_FILE_POINTER) + LARGE_INTEGER li; + li.QuadPart = static_cast(position); + if (!SetFilePointerEx(nativeHandle, li, nullptr, nativeSeekType)) { if (auto errCode = GetLastError(); errCode != ERROR_SUCCESS) {