diff cli-main.c @ 1025:02baa0b334e8 fastopen

async connections working
author Matt Johnston <matt@ucc.asn.au>
date Wed, 18 Feb 2015 22:46:15 +0800
parents 4121ca987e6a
children daf21fd50abf
line wrap: on
line diff
--- a/cli-main.c	Wed Feb 18 00:05:27 2015 +0800
+++ b/cli-main.c	Wed Feb 18 22:46:15 2015 +0800
@@ -72,12 +72,8 @@
 	} else
 #endif
 	{
-		int sock = connect_remote(cli_opts.remotehost, cli_opts.remoteport, &error);
-		sock_in = sock_out = sock;
-	}
-
-	if (sock_in < 0) {
-		dropbear_exit("%s", error);
+		connect_remote(cli_opts.remotehost, cli_opts.remoteport, cli_connected, NULL);
+		sock_in = sock_out = -1;
 	}
 
 	cli_session(sock_in, sock_out);