1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 02:32:36 +01:00

VFS: fix off-by-one error in vfs::escape()

This commit is contained in:
QuadDamage 2020-09-07 15:20:35 -07:00 committed by Megamouse
parent 9134388f94
commit 60f8fc293d

View File

@ -320,7 +320,7 @@ std::string vfs::escape(std::string_view name, bool escape_slash)
case "COM"_u32:
case "LPT"_u32:
{
if (name.size() >= 4 && name[3] >= '1' && name[4] <= '9')
if (name.size() >= 4 && name[3] >= '1' && name[3] <= '9')
{
if (name.size() == 4 || name[4] == '.')
{