1
0
Fork 0
mirror of https://github.com/Jackett/Jackett synced 2025-01-01 12:46:23 +00:00

core: fix installation path with spaces (#10489)

This commit is contained in:
Diego Heras 2020-12-12 22:14:56 +01:00 committed by GitHub
parent 13baa27656
commit d77b7c3616
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -516,7 +516,7 @@ namespace Jackett.Updater
if (isWindows)
{
//User didn't initiate the update from Windows service and wasn't running Jackett via the tray, must have started from the console
startInfo.Arguments = $"/K {startInfo.FileName} {startInfo.Arguments}";
startInfo.Arguments = $"/K \"{startInfo.FileName}\" {startInfo.Arguments}";
startInfo.FileName = "cmd.exe";
startInfo.CreateNoWindow = false;
startInfo.WindowStyle = ProcessWindowStyle.Normal;
@ -524,7 +524,7 @@ namespace Jackett.Updater
if (variant == Variants.JackettVariant.Mono)
{
startInfo.Arguments = startInfo.FileName + " " + startInfo.Arguments;
startInfo.Arguments = $"\"{startInfo.FileName}\" {startInfo.Arguments}";
startInfo.FileName = "mono";
}
@ -535,7 +535,7 @@ namespace Jackett.Updater
startInfo.CreateNoWindow = true;
}
logger.Info("Starting Jackett: " + startInfo.FileName + " " + startInfo.Arguments);
logger.Info($"Starting Jackett: \"{startInfo.FileName }\" {startInfo.Arguments}");
Process.Start(startInfo);
}
}