Adding OSPlatform Processing

This commit is contained in:
2dust
2024-08-26 18:45:41 +08:00
parent b57cdd31bd
commit 6f3e4b3682
2 changed files with 15 additions and 2 deletions
+2 -2
View File
@@ -116,7 +116,7 @@ namespace ServiceLib.Handler
foreach (Process p in existing)
{
string? path = p.MainModule?.FileName;
if (path == $"{Utils.GetBinPath(vName, it.coreType.ToString())}.exe")
if (path == Utils.GetExeName(Utils.GetBinPath(vName, it.coreType.ToString())))
{
KillProcess(p);
}
@@ -151,7 +151,7 @@ namespace ServiceLib.Handler
string fileName = string.Empty;
foreach (string name in coreInfo.coreExes)
{
string vName = $"{name}.exe";
string vName = Utils.GetExeName(name);
vName = Utils.GetBinPath(vName, coreInfo.coreType.ToString());
if (File.Exists(vName))
{