Fix for restarting if there's a space in the profile name

This commit is contained in:
Patrick Simpson 2017-09-14 15:21:32 +03:00
parent 6afaa7aeba
commit 0da8086fa7
1 changed files with 5 additions and 1 deletions

View File

@ -76,10 +76,14 @@ namespace OutlookRestarter
string path = procArgs[i];
HandleCleanKoe(path);
}
else
else if (procArgs[i].StartsWith("/"))
{
useArgs.Add(procArgs[i]);
}
else
{
useArgs.Add("\"" + procArgs[i] + "\"");
}
}
string argsString = string.Join(" ", useArgs);
Logger.Instance.Debug(typeof(OutlookRestarter), "Parsed arguments: {0}", argsString);