diff --git a/Duplicati/CommandLine/Program.cs b/Duplicati/CommandLine/Program.cs index 6deb3fa92..5381ebd1e 100644 --- a/Duplicati/CommandLine/Program.cs +++ b/Duplicati/CommandLine/Program.cs @@ -55,7 +55,7 @@ namespace Duplicati.CommandLine //If we are on Windows, append the bundled "win-tools" programs to the search path //We add it last, to allow the user to override with other versions - if (!Library.Utility.Utility.IsClientLinux) + if (Library.Utility.Utility.IsClientWindows) { string wintools = System.IO.Path.Combine(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), "win-tools"); Environment.SetEnvironmentVariable("PATH", diff --git a/Duplicati/Server/Program.cs b/Duplicati/Server/Program.cs index 77366f03b..5e488bf9f 100644 --- a/Duplicati/Server/Program.cs +++ b/Duplicati/Server/Program.cs @@ -162,7 +162,7 @@ namespace Duplicati.Server { //If we are on Windows, append the bundled "win-tools" programs to the search path //We add it last, to allow the user to override with other versions - if (!Library.Utility.Utility.IsClientLinux) + if (Library.Utility.Utility.IsClientWindows) { Environment.SetEnvironmentVariable("PATH", Environment.GetEnvironmentVariable("PATH") + @@ -257,6 +257,7 @@ namespace Duplicati.Server { //Portable mode uses a data folder in the application home dir Environment.SetEnvironmentVariable(DATAFOLDER_ENV_NAME, System.IO.Path.Combine(StartupPath, "data")); + System.IO.Directory.SetCurrentDirectory(StartupPath); } else {