mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-08 19:07:48 +00:00
Avoid performance warning in MSVC compilation.
https://msdn.microsoft.com/en-us/library/windows/desktop/bb773674.aspx says PathIsRootW() returns TRUE or FALSE.
This commit is contained in:
parent
67d094d06f
commit
75278bac02
@ -981,7 +981,7 @@ bool is_root(const std::string& path)
|
||||
// See also: <https://googleprojectzero.blogspot.com/2016/02/the-definitive-guide-on-win32-to-nt.html>
|
||||
//
|
||||
const std::wstring& wpath = bfs::path{path}.make_preferred().wstring();
|
||||
return PathIsRootW(wpath.c_str());
|
||||
return PathIsRootW(wpath.c_str()) == TRUE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user