comparison main.c @ 5:bc6477a6c393

syntactical fixups - it compiles, but channel handling code requires fixing.
author Matt Johnston <matt@ucc.asn.au>
date Tue, 01 Jun 2004 04:20:12 +0000
parents fe6bca95afa7
children 469950e86d0f
comparison
equal deleted inserted replaced
4:fe6bca95afa7 5:bc6477a6c393
60 pid_t childpid; 60 pid_t childpid;
61 int childpipe[2]; 61 int childpipe[2];
62 62
63 struct sigaction sa_chld; 63 struct sigaction sa_chld;
64 64
65 _dropbear_exit = svr_dropbear_exit;
66 _dropbear_log = svr_dropbear_log;
67
65 /* get commandline options */ 68 /* get commandline options */
66 opts = getrunopts(argc, argv); 69 opts = svr_getopts(argc, argv);
67 70
68 /* fork */ 71 /* fork */
69 if (opts->forkbg) { 72 if (opts->forkbg) {
70 int closefds = 0; 73 int closefds = 0;
71 #ifndef DEBUG_TRACE 74 #ifndef DEBUG_TRACE
237 240
238 if (m_close(childpipe[0]) == DROPBEAR_FAILURE) { 241 if (m_close(childpipe[0]) == DROPBEAR_FAILURE) {
239 dropbear_exit("Couldn't close socket"); 242 dropbear_exit("Couldn't close socket");
240 } 243 }
241 /* start the session */ 244 /* start the session */
242 child_session(childsock, opts, childpipe[1], &remoteaddr); 245 svr_session(childsock, opts, childpipe[1], &remoteaddr);
243 /* don't return */ 246 /* don't return */
244 assert(0); 247 assert(0);
245 } 248 }
246 249
247 /* parent */ 250 /* parent */