[fetcher] no need to keep error message in memory

This commit is contained in:
Hylke Bons 2011-03-12 16:18:36 +00:00
parent 73bf910896
commit 714a55b32a

View file

@ -37,7 +37,6 @@ namespace SparkleLib {
private string TargetFolder;
private string RemoteOriginUrl;
private string Command_Error;
public SparkleFetcher (string url, string folder)
{
@ -79,8 +78,10 @@ namespace SparkleLib {
SparkleHelpers.DebugInfo ("Git", "Exit code " + process.ExitCode.ToString ());
if (process.ExitCode != 0) {
string error = process.StandardError.ReadToEnd ();
SparkleHelpers.DebugInfo ("Git", "Error: " + Command_Error);
SparkleHelpers.DebugInfo ("Git", "Error: " + error);
SparkleHelpers.DebugInfo ("Git", "[" + TargetFolder + "] Cloning failed");
if (CloningFailed != null)
@ -101,8 +102,8 @@ namespace SparkleLib {
};
process.Start ();
Command_Error = process.StandardError.ReadToEnd ();
process.WaitForExit ();
}