diff --git a/src/rufus.rc b/src/rufus.rc index 18f77096ca7..da315559259 100644 --- a/src/rufus.rc +++ b/src/rufus.rc @@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL IDD_DIALOG DIALOGEX 12, 12, 232, 326 STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU EXSTYLE WS_EX_ACCEPTFILES -CAPTION "Rufus 4.5.2154" +CAPTION "Rufus 4.5.2155" FONT 9, "Segoe UI Symbol", 400, 0, 0x0 BEGIN LTEXT "Drive Properties",IDS_DRIVE_PROPERTIES_TXT,8,6,53,12,NOT WS_GROUP @@ -397,8 +397,8 @@ END // VS_VERSION_INFO VERSIONINFO - FILEVERSION 4,5,2154,0 - PRODUCTVERSION 4,5,2154,0 + FILEVERSION 4,5,2155,0 + PRODUCTVERSION 4,5,2155,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -416,13 +416,13 @@ BEGIN VALUE "Comments", "https://rufus.ie" VALUE "CompanyName", "Akeo Consulting" VALUE "FileDescription", "Rufus" - VALUE "FileVersion", "4.5.2154" + VALUE "FileVersion", "4.5.2155" VALUE "InternalName", "Rufus" VALUE "LegalCopyright", "� 2011-2024 Pete Batard (GPL v3)" VALUE "LegalTrademarks", "https://www.gnu.org/licenses/gpl-3.0.html" VALUE "OriginalFilename", "rufus-4.5.exe" VALUE "ProductName", "Rufus" - VALUE "ProductVersion", "4.5.2154" + VALUE "ProductVersion", "4.5.2155" END END BLOCK "VarFileInfo" diff --git a/src/winio.h b/src/winio.h index 6213721b2a8..007828080e8 100644 --- a/src/winio.h +++ b/src/winio.h @@ -2,7 +2,7 @@ * Rufus: The Reliable USB Formatting Utility * Windows I/O redefinitions, that would be totally unnecessary had * Microsoft done a proper job with their asynchronous APIs. -* Copyright © 2021 Pete Batard +* Copyright © 2021-2024 Pete Batard * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -165,10 +165,10 @@ static __inline BOOL GetSizeAsync(HANDLE h, LPDWORD lpNumberOfBytes) SetLastError(ERROR_NO_MORE_ITEMS); return FALSE; } - // TODO: Use a timeout and call GetOverlappedResultEx() on Windows 8 and later - if (!GetOverlappedResult(fd->hFile, (OVERLAPPED*)&fd->Overlapped, - lpNumberOfBytes, (fd->iStatus < 0))) - return (GetLastError() == ERROR_HANDLE_EOF); + if (!GetOverlappedResultEx(fd->hFile, (OVERLAPPED*)&fd->Overlapped, + lpNumberOfBytes, WRITE_TIMEOUT, (fd->iStatus < 0))) + // When reading from VHD/VHDX we get SECTOR_NOT_FOUND rather than EOF for the end of the drive + return (GetLastError() == ERROR_HANDLE_EOF || GetLastError() == ERROR_SECTOR_NOT_FOUND); fd->Overlapped.Offset += *lpNumberOfBytes; fd->Overlapped.bOffsetUpdated = TRUE; return TRUE;