[*] FS path mitigation: begin to handle >= MAX_PATHs by enforcing UNC \\?\ prefixes across every single Win32/NT api we hit (if relevant. im sure some long paths may still break things.)

This commit is contained in:
Reece Wilson 2023-09-10 23:49:23 +01:00
parent d727859cc2
commit 92593be412

View File

@ -180,6 +180,16 @@ namespace Aurora::IO::FS
result = path;
}
}
#if defined(AURORA_IS_MODERNNT_DERIVED)
if (result.size() >= MAX_PATH)
{
if (!AuStartsWith(result, "\\\\"))
{
result = "\\\\?\\" + result;
}
}
#endif
}
void /* internal, local export */ _NormalizePath(AuString &str)