mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 20:42:21 +02:00
Fixed BfpFile_GetActualPath
This commit is contained in:
parent
9210346853
commit
4479af6df4
1 changed files with 7 additions and 3 deletions
|
@ -3260,10 +3260,14 @@ BFP_EXPORT void BFP_CALLTYPE BfpFile_GetActualPath(const char* inPathC, char* ou
|
|||
subName[j] = DIR_SEP_CHAR;
|
||||
info.szDisplayName[0] = 0;
|
||||
int32 size = (int32)sizeof(SHFILEINFOW);
|
||||
if (SHGetFileInfoW(UTF8Decode(subName).c_str(), 0, &info, (int32)sizeof(SHFILEINFOW), SHGFI_DISPLAYNAME))
|
||||
|
||||
WIN32_FIND_DATAW findData;
|
||||
HANDLE handleVal = FindFirstFileW(UTF8Decode(subName).c_str(), &findData);
|
||||
if (handleVal != INVALID_HANDLE_VALUE)
|
||||
{
|
||||
outPath.Append(UTF8Encode(info.szDisplayName));
|
||||
}
|
||||
outPath.Append(UTF8Encode(findData.cFileName));
|
||||
FindClose(handleVal);
|
||||
}
|
||||
else
|
||||
{
|
||||
// most likely file does not exist.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue