Commit f6bd0863352f70905b3068284f8ccd6beaa9a590

Etienne Samson 2013-07-03T22:02:44

Fix a probable leak.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/src/transports/ssh.c b/src/transports/ssh.c
index 8e3657d..f2480b2 100644
--- a/src/transports/ssh.c
+++ b/src/transports/ssh.c
@@ -351,7 +351,7 @@ static int _git_ssh_setup_conn(
 				user,
 				GIT_CREDTYPE_USERPASS_PLAINTEXT | GIT_CREDTYPE_SSH_KEYFILE_PASSPHRASE,
 				t->owner->cred_acquire_payload) < 0)
-			return -1;
+			goto on_error;
 	} else {
         goto on_error;
     }