comparison cli-main.c @ 1022:4121ca987e6a

connect_remote() is now always non-blocking
author Matt Johnston <matt@ucc.asn.au>
date Sat, 14 Feb 2015 09:56:11 +0800
parents 257f7d5fca97
children 02baa0b334e8
comparison
equal deleted inserted replaced
1021:24135c8e1d46 1022:4121ca987e6a
70 cli_proxy_cmd(&sock_in, &sock_out); 70 cli_proxy_cmd(&sock_in, &sock_out);
71 m_free(cli_opts.proxycmd); 71 m_free(cli_opts.proxycmd);
72 } else 72 } else
73 #endif 73 #endif
74 { 74 {
75 int sock = connect_remote(cli_opts.remotehost, cli_opts.remoteport, 75 int sock = connect_remote(cli_opts.remotehost, cli_opts.remoteport, &error);
76 1, &error);
77 sock_in = sock_out = sock; 76 sock_in = sock_out = sock;
78 } 77 }
79 78
80 if (sock_in < 0) { 79 if (sock_in < 0) {
81 dropbear_exit("%s", error); 80 dropbear_exit("%s", error);