From 639a777bfe7dd24f0afe2ad0a28a4e12d2c1a198 Mon Sep 17 00:00:00 2001 From: Konstantinos Vaggelakos Date: Wed, 2 Nov 2011 21:48:43 +0100 Subject: [PATCH] Added exceptionhandling for the ssh-agent killing --- SparkleShare/SparkleControllerBase.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SparkleShare/SparkleControllerBase.cs b/SparkleShare/SparkleControllerBase.cs index 03f71f39..d8a94d4a 100644 --- a/SparkleShare/SparkleControllerBase.cs +++ b/SparkleShare/SparkleControllerBase.cs @@ -1152,8 +1152,8 @@ namespace SparkleShare { try { int pid = Int32.Parse (System.Environment.GetEnvironmentVariable ("SSH_AGENT_PID")); Process.GetProcessById (pid).Kill (); - } catch (Exception e) { - // Handle exception if needed + } catch (ArgumentException) { + SparkleHelpers.DebugInfo ("SSH", "Could not kill the ssh-agent, due to the process wasn't running"); } #endif }