File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 99#include < algorithm>
1010
1111#include " flutter/fml/paths.h"
12+ #include " flutter/fml/platform/win/wstring_conversion.h"
1213
1314namespace fml {
1415namespace paths {
@@ -58,12 +59,12 @@ std::pair<bool, std::string> GetExecutablePath() {
5859 if (module == NULL ) {
5960 return {false , " " };
6061 }
61- char path[MAX_PATH];
62- DWORD read_size = GetModuleFileNameA (module , path, MAX_PATH);
62+ wchar_t path[MAX_PATH];
63+ DWORD read_size = GetModuleFileNameW (module , path, MAX_PATH);
6364 if (read_size == 0 || read_size == MAX_PATH) {
6465 return {false , " " };
6566 }
66- return {true , std::string {path, read_size}};
67+ return {true , WideStringToUtf8 ( {path, read_size}) };
6768}
6869
6970std::string AbsolutePath (const std::string& path) {
You can’t perform that action at this time.
0 commit comments