Skip to content

Commit 6753c6e

Browse files
perminovVSminggo
authored andcommitted
[WinRT] Fix removeDirectory unicode. (#17812)
CCFileUtilsWinRT::removeDirectory need ut8 string. temp is wstring(unicode).
1 parent 9c2782f commit 6753c6e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cocos/platform/winrt/CCFileUtilsWinRT.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ bool CCFileUtilsWinRT::removeDirectory(const std::string& path)
286286
if (wfd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
287287
{
288288
temp += '/';
289-
ret = ret && this->removeDirectory(std::string(temp.begin(), temp.end()));
289+
ret = ret && this->removeDirectory(StringWideCharToUtf8(temp));
290290
}
291291
else
292292
{

0 commit comments

Comments
 (0)