From 7316ed33e1114f27db77790f55984caede5318fe Mon Sep 17 00:00:00 2001 From: Nicolas Viennot Date: Fri, 14 Jun 2013 23:52:31 -0400 Subject: [PATCH] [libssh] auth: If the agent fails, fall back to regular path It's causing issues on MacOSX when ssh_agent_get_ident_count() reports "Agent count: 0". --- libssh/src/auth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libssh/src/auth.c b/libssh/src/auth.c index 9d099a53..5b8f748f 100644 --- a/libssh/src/auth.c +++ b/libssh/src/auth.c @@ -1109,7 +1109,7 @@ int ssh_userauth_publickey_auto(ssh_session session, #ifndef _WIN32 /* Try authentication with ssh-agent first */ rc = ssh_userauth_agent(session, username); - if (rc == SSH_AUTH_ERROR || rc == SSH_AUTH_SUCCESS) { + if (rc == SSH_AUTH_SUCCESS) { return rc; } if (rc == SSH_AUTH_AGAIN)