diff --git a/Duplicati/GUI/Duplicati.GUI.TrayIcon/Program.cs b/Duplicati/GUI/Duplicati.GUI.TrayIcon/Program.cs index 3349bc39e..cf9bddc47 100644 --- a/Duplicati/GUI/Duplicati.GUI.TrayIcon/Program.cs +++ b/Duplicati/GUI/Duplicati.GUI.TrayIcon/Program.cs @@ -210,6 +210,9 @@ namespace Duplicati.GUI.TrayIcon // If the server shuts down, shut down the tray-icon as well Action shutdownEvent = () => { + // Make sure we do not start again after + // a controlled exit + reSpawn = 100; tk.InvokeExit(); }; @@ -218,6 +221,9 @@ namespace Duplicati.GUI.TrayIcon tk.Init(_args); + // If the tray-icon quits, stop the server + reSpawn = 100; + // Make sure that the server shutdown does not access the tray-icon, // as it would be disposed by now if (hosted != null)