1
1
Fork 0
mirror of https://github.com/pbatard/rufus.git synced 2024-08-14 23:57:05 +00:00

[misc] fix XP breakage

* Can't wait until XP support is dropped from Rufus altogether...
This commit is contained in:
Pete Batard 2015-09-28 02:32:11 +01:00
parent 9411716074
commit 5025e27228
2 changed files with 37 additions and 5 deletions

View file

@ -768,6 +768,37 @@ static __inline int _chdirU(const char *dirname)
return ret;
}
#if defined(_WIN32_WINNT) && (_WIN32_WINNT <= 0x501)
static __inline FILE* fopenU(const char* filename, const char* mode)
{
FILE* ret = NULL;
wconvert(filename);
wconvert(mode);
ret = _wfopen(wfilename, wmode);
wfree(filename);
wfree(mode);
return ret;
}
static __inline int _openU(const char *filename, int oflag, int pmode)
{
int ret = -1;
wconvert(filename);
ret = _wopen(wfilename, oflag, pmode);
wfree(filename);
return ret;
}
// returned UTF-8 string must be freed
static __inline char* getenvU(const char* varname)
{
wconvert(varname);
char* ret;
ret = wchar_to_utf8(_wgetenv(wvarname));
wfree(varname);
return ret;
}
#else
static __inline FILE* fopenU(const char* filename, const char* mode)
{
FILE* ret = NULL;
@ -807,6 +838,7 @@ static __inline char* getenvU(const char* varname)
wfree(varname);
return ret;
}
#endif
static __inline int _mkdirU(const char* dirname)
{

View file

@ -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.756"
CAPTION "Rufus 2.4.757"
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,756,0
PRODUCTVERSION 2,4,756,0
FILEVERSION 2,4,757,0
PRODUCTVERSION 2,4,757,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.756"
VALUE "FileVersion", "2.4.757"
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.756"
VALUE "ProductVersion", "2.4.757"
END
END
BLOCK "VarFileInfo"