summaryrefslogtreecommitdiffhomepage
path: root/cli-session.c
diff options
context:
space:
mode:
Diffstat (limited to 'cli-session.c')
-rw-r--r--cli-session.c9
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);