git: only add new language env var if it doesn't exist yet. fixes #1191

This commit is contained in:
Hylke Bons 2013-02-21 13:53:23 +00:00
parent 85cea028ef
commit 89120dc377

View file

@ -117,7 +117,10 @@ namespace SparkleLib.Git {
StartInfo.WorkingDirectory = path;
StartInfo.CreateNoWindow = true;
StartInfo.EnvironmentVariables.Add ("LANG", "en_US");
if (StartInfo.EnvironmentVariables.ContainsKey ("LANG"))
StartInfo.EnvironmentVariables ["LANG"] = "en_US";
else
StartInfo.EnvironmentVariables.Add ("LANG", "en_US");
if (string.IsNullOrEmpty (ExecPath))
StartInfo.Arguments = args;