diff --git a/src/format.c b/src/format.c index 76b64eb5..3c1f4d1c 100644 --- a/src/format.c +++ b/src/format.c @@ -1975,7 +1975,7 @@ DWORD WINAPI SaveImageThread(void* param) { BOOL s; DWORD rSize, wSize; - VHD_SAVE *vhd_save = param; + VHD_SAVE *vhd_save = (VHD_SAVE*)param; HANDLE hPhysicalDrive = INVALID_HANDLE_VALUE; HANDLE hDestImage = INVALID_HANDLE_VALUE; LARGE_INTEGER li; diff --git a/src/rufus.c b/src/rufus.c index 314824ad..f79b29e4 100644 --- a/src/rufus.c +++ b/src/rufus.c @@ -1989,15 +1989,18 @@ void SetBoot(int fs, int tt) void SaveVHD(void) { + static VHD_SAVE vhd_save; char filename[128]; char path[MAX_PATH]; int DriveIndex = ComboBox_GetCurSel(hDeviceList); + EXT_DECL(vhd_ext, filename, __VA_GROUP__("*.vhd"), __VA_GROUP__("VHD File")); + ULARGE_INTEGER free_space; + if (DriveIndex >= 0) safe_sprintf(filename, sizeof(filename), "%s.vhd", DriveLabel.String[DriveIndex]); if ((DriveIndex != CB_ERR) && (!format_op_in_progress) && (format_thid == NULL)) { - EXT_DECL(vhd_ext, filename, __VA_GROUP__("*.vhd"), __VA_GROUP__("VHD File")); - ULARGE_INTEGER free_space; - VHD_SAVE vhd_save = { (DWORD)ComboBox_GetItemData(hDeviceList, DriveIndex), FileDialog(TRUE, NULL, &vhd_ext, 0) }; + vhd_save.DeviceNum = (DWORD)ComboBox_GetItemData(hDeviceList, DriveIndex); + vhd_save.path = FileDialog(TRUE, NULL, &vhd_ext, 0); if (vhd_save.path != NULL) { // Reset all progress bars SendMessage(hProgress, PBM_SETSTATE, (WPARAM)PBST_NORMAL, 0); diff --git a/src/rufus.rc b/src/rufus.rc index dc6edbc8..a8c67635 100644 --- a/src/rufus.rc +++ b/src/rufus.rc @@ -32,7 +32,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL IDD_DIALOG DIALOGEX 12, 12, 242, 376 STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Rufus 2.4.723" +CAPTION "Rufus 2.4.724" FONT 8, "Segoe UI Symbol", 400, 0, 0x0 BEGIN LTEXT "Device",IDS_DEVICE_TXT,9,6,200,8 @@ -317,8 +317,8 @@ END // VS_VERSION_INFO VERSIONINFO - FILEVERSION 2,4,723,0 - PRODUCTVERSION 2,4,723,0 + FILEVERSION 2,4,724,0 + PRODUCTVERSION 2,4,724,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -335,13 +335,13 @@ BEGIN BEGIN VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)" VALUE "FileDescription", "Rufus" - VALUE "FileVersion", "2.4.723" + VALUE "FileVersion", "2.4.724" VALUE "InternalName", "Rufus" VALUE "LegalCopyright", "© 2011-2015 Pete Batard (GPL v3)" VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html" VALUE "OriginalFilename", "rufus.exe" VALUE "ProductName", "Rufus" - VALUE "ProductVersion", "2.4.723" + VALUE "ProductVersion", "2.4.724" END END BLOCK "VarFileInfo"