From 9d7fc9d50b895650f1ec301021b4a202a0fcb3cb Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Tue, 11 May 2010 02:08:29 +0200 Subject: Use the new expand functions. This implements escape chars for IdentityFile in ssh_config and reads the system ssh_config. --- libssh/client.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'libssh/client.c') diff --git a/libssh/client.c b/libssh/client.c index 56267784..3999f990 100644 --- a/libssh/client.c +++ b/libssh/client.c @@ -482,6 +482,7 @@ int ssh_connect(ssh_session session) { int ssh1 = 0; int ssh2 = 0; int fd = -1; + int ret; if (session == NULL) { ssh_set_error(session, SSH_FATAL, "Invalid session pointer"); @@ -503,6 +504,14 @@ int ssh_connect(ssh_session session) { leave_function(); return SSH_ERROR; } + + ret = ssh_options_apply(session); + if (ret < 0) { + ssh_set_error(session, SSH_FATAL, "Couldn't apply options"); + leave_function(); + return SSH_ERROR; + } + if (session->fd != -1) { fd = session->fd; #ifndef _WIN32 -- cgit