mirror of
https://github.com/pbatard/rufus.git
synced 2025-05-19 17:35:10 -04:00
[misc] fix a new set of MinGW warnings
This commit is contained in:
parent
b9da0cf057
commit
2495f2d444
4 changed files with 11 additions and 11 deletions
|
@ -167,7 +167,7 @@ char* GetPhysicalName(DWORD DriveIndex)
|
|||
char physical_name[24];
|
||||
|
||||
CheckDriveIndex(DriveIndex);
|
||||
safe_sprintf(physical_name, sizeof(physical_name), "\\\\.\\PHYSICALDRIVE%d", DriveIndex);
|
||||
safe_sprintf(physical_name, sizeof(physical_name), "\\\\.\\PHYSICALDRIVE%lu", DriveIndex);
|
||||
success = TRUE;
|
||||
out:
|
||||
return (success)?safe_strdup(physical_name):NULL;
|
||||
|
|
|
@ -203,7 +203,7 @@ const char* WinInetErrorString(void)
|
|||
InternetGetLastResponseInfoA(&error_code, error_string, &size);
|
||||
return error_string;
|
||||
default:
|
||||
safe_sprintf(error_string, sizeof(error_string), "Unknown internet error 0x%08X", error_code);
|
||||
safe_sprintf(error_string, sizeof(error_string), "Unknown internet error 0x%08luX", error_code);
|
||||
return error_string;
|
||||
}
|
||||
}
|
||||
|
@ -490,7 +490,7 @@ static DWORD WINAPI CheckForUpdatesThread(LPVOID param)
|
|||
// and then remove each each of the <os_> components until we find our match. For instance, we may first
|
||||
// look for rufus_win_x64_6.2.ver (Win8 x64) but only get a match for rufus_win_x64_6.ver (Vista x64 or later)
|
||||
// This allows sunsetting OS versions (eg XP) or providing different downloads for different archs/groups.
|
||||
safe_sprintf(urlpath, sizeof(urlpath), "%s%s%s_%s_%d.%d.ver", APPLICATION_NAME, (k==0)?"":"_",
|
||||
safe_sprintf(urlpath, sizeof(urlpath), "%s%s%s_%s_%lu.%lu.ver", APPLICATION_NAME, (k==0)?"":"_",
|
||||
(k==0)?"":channel[k], archname[is_x64()?1:0], os_version.dwMajorVersion, os_version.dwMinorVersion);
|
||||
vuprintf("Base update check: %s\n", urlpath);
|
||||
for (i=0, j=(int)safe_strlen(urlpath)-5; (j>0)&&(i<ARRAYSIZE(verpos)); j--) {
|
||||
|
|
10
src/rufus.rc
10
src/rufus.rc
|
@ -33,7 +33,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
|
||||
EXSTYLE WS_EX_ACCEPTFILES
|
||||
CAPTION "Rufus 2.10.942"
|
||||
CAPTION "Rufus 2.10.943"
|
||||
FONT 8, "Segoe UI Symbol", 400, 0, 0x0
|
||||
BEGIN
|
||||
LTEXT "Device",IDS_DEVICE_TXT,9,6,200,8
|
||||
|
@ -320,8 +320,8 @@ END
|
|||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 2,10,942,0
|
||||
PRODUCTVERSION 2,10,942,0
|
||||
FILEVERSION 2,10,943,0
|
||||
PRODUCTVERSION 2,10,943,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
|
@ -338,13 +338,13 @@ BEGIN
|
|||
BEGIN
|
||||
VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)"
|
||||
VALUE "FileDescription", "Rufus"
|
||||
VALUE "FileVersion", "2.10.942"
|
||||
VALUE "FileVersion", "2.10.943"
|
||||
VALUE "InternalName", "Rufus"
|
||||
VALUE "LegalCopyright", "© 2011-2016 Pete Batard (GPL v3)"
|
||||
VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html"
|
||||
VALUE "OriginalFilename", "rufus.exe"
|
||||
VALUE "ProductName", "Rufus"
|
||||
VALUE "ProductVersion", "2.10.942"
|
||||
VALUE "ProductVersion", "2.10.943"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
|
|
@ -148,7 +148,7 @@ static char err_string[256] = {0};
|
|||
|
||||
error_code = GetLastError();
|
||||
|
||||
safe_sprintf(err_string, sizeof(err_string), "[0x%08X] ", error_code);
|
||||
safe_sprintf(err_string, sizeof(err_string), "[0x%08luX] ", error_code);
|
||||
|
||||
size = FormatMessageU(FORMAT_MESSAGE_FROM_SYSTEM|FORMAT_MESSAGE_IGNORE_INSERTS, NULL, HRESULT_CODE(error_code),
|
||||
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), &err_string[strlen(err_string)],
|
||||
|
@ -157,9 +157,9 @@ static char err_string[256] = {0};
|
|||
format_error = GetLastError();
|
||||
if ((format_error) && (format_error != 0x13D)) // 0x13D, decode error, is returned for unknown codes
|
||||
safe_sprintf(err_string, sizeof(err_string),
|
||||
"Windows error code 0x%08X (FormatMessage error code 0x%08X)", error_code, format_error);
|
||||
"Windows error code 0x%08luX (FormatMessage error code 0x%08luX)", error_code, format_error);
|
||||
else
|
||||
safe_sprintf(err_string, sizeof(err_string), "Unknown error 0x%08X", error_code);
|
||||
safe_sprintf(err_string, sizeof(err_string), "Unknown error 0x%08luX", error_code);
|
||||
}
|
||||
|
||||
SetLastError(error_code); // Make sure we don't change the errorcode on exit
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue