diff --git a/TGInstallerWrapper/Main.cs b/TGInstallerWrapper/Main.cs index 09f1b8243b..0372aa7204 100644 --- a/TGInstallerWrapper/Main.cs +++ b/TGInstallerWrapper/Main.cs @@ -68,6 +68,21 @@ namespace TGInstallerWrapper string logfile = null; try { + while (true) + { + var res = PromptKillProcess("TGCommandLine"); + if (res == PKillType.Aborted) + return; + else if (res == PKillType.Killed) + continue; + res = PromptKillProcess("TGControlPanel"); + if (res == PKillType.Aborted) + return; + else if (res == PKillType.Killed) + continue; + break; + } + var args = new List(); if (!pathIsDefault) args.Add(String.Format("INSTALLFOLDER=\"{0}\"", PathTextBox.Text)); @@ -114,21 +129,6 @@ namespace TGInstallerWrapper } } - while (true) - { - var res = PromptKillProcess("TGCommandLine"); - if (res == PKillType.Aborted) - return; - else if (res == PKillType.Killed) - continue; - res = PromptKillProcess("TGControlPanel"); - if (res == PKillType.Aborted) - return; - else if (res == PKillType.Killed) - continue; - break; - } - InstallCancelButton.Enabled = true; if (ShowLogCheckbox.Checked)