Installers: Fix Steam library manifest parsing. Fixes #21129

This commit is contained in:
Jakub Vesely
2023-10-21 15:59:24 +02:00
committed by Gustas
parent e83e580f23
commit 3be1de230c

View File

@@ -109,10 +109,15 @@ namespace OpenRA.Mods.Common.Installer
continue;
foreach (var e in ParseLibraryManifest(libraryFoldersPath).Where(e => e.Item1 == "path"))
yield return e.Item2;
yield return Unescape(e.Item2);
}
}
static string Unescape(string path)
{
return path.Replace(@"\\", @"\");
}
static Dictionary<string, string> ParseGameManifest(string path)
{
var regex = new Regex("^\\s*\"(?<key>[^\"]*)\"\\s*\"(?<value>[^\"]*)\"\\s*$");