version 1.411, 2015/01/08 10:15:45 |
version 1.412, 2015/01/14 20:05:27 |
|
|
#include "uidswap.h" |
#include "uidswap.h" |
#include "roaming.h" |
#include "roaming.h" |
#include "version.h" |
#include "version.h" |
|
#include "ssherr.h" |
|
|
#ifdef ENABLE_PKCS11 |
#ifdef ENABLE_PKCS11 |
#include "ssh-pkcs11.h" |
#include "ssh-pkcs11.h" |
|
|
static void |
static void |
check_agent_present(void) |
check_agent_present(void) |
{ |
{ |
|
int r; |
|
|
if (options.forward_agent) { |
if (options.forward_agent) { |
/* Clear agent forwarding if we don't have an agent. */ |
/* Clear agent forwarding if we don't have an agent. */ |
if (!ssh_agent_present()) |
if ((r = ssh_get_authentication_socket(NULL)) != 0) { |
options.forward_agent = 0; |
options.forward_agent = 0; |
|
if (r != SSH_ERR_AGENT_NOT_PRESENT) |
|
debug("ssh_get_authentication_socket: %s", |
|
ssh_err(r)); |
|
} |
} |
} |
} |
} |
|
|