diff options
author | Matt Johnston <matt@ucc.asn.au> | 2015-02-18 22:46:15 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2015-02-18 22:46:15 +0800 |
commit | 3206e75c9eeab66103774bd217cf33feb1e39976 (patch) | |
tree | 24d0172c93c17e7ea3e49e479ad1b9e4da9e7d88 /cli-session.c | |
parent | ae8c94249d1df9e69d48f9998aa202a909d7074c (diff) | |
download | dropbear-3206e75c9eeab66103774bd217cf33feb1e39976.tar.gz |
async connections working
Diffstat (limited to 'cli-session.c')
-rw-r--r-- | cli-session.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/cli-session.c b/cli-session.c index a484bf7..a5ae728 100644 --- a/cli-session.c +++ b/cli-session.c @@ -93,6 +93,15 @@ static const struct ChanType *cli_chantypes[] = { NULL /* Null termination */ }; +void cli_connected(int result, int sock, void* userdata, const char *errstring) +{ + if (result == DROPBEAR_FAILURE) + { + dropbear_exit("Connect failed: %s", errstring); + } + ses.sock_in = ses.sock_out = sock; +} + void cli_session(int sock_in, int sock_out) { common_session_init(sock_in, sock_out); |