comparison svr-main.c @ 113:775c6cbfe995

Load the hostkeys for inetd too - oops
author Matt Johnston <matt@ucc.asn.au>
date Mon, 30 Aug 2004 13:26:42 +0000
parents 10f4d3319780
children 8c2b3506f112
comparison
equal deleted inserted replaced
112:cca368f09f4f 113:775c6cbfe995
136 } 136 }
137 } 137 }
138 138
139 commonsetup(); 139 commonsetup();
140 140
141 /* Now we can setup the hostkeys - needs to be after logging is on,
142 * otherwise we might end up blatting error messages to the socket */
143 loadhostkeys();
144 141
145 /* should be done after syslog is working */ 142 /* should be done after syslog is working */
146 if (svr_opts.forkbg) { 143 if (svr_opts.forkbg) {
147 dropbear_log(LOG_INFO, "Running in background"); 144 dropbear_log(LOG_INFO, "Running in background");
148 } else { 145 } else {
353 dropbear_exit("signal() error"); 350 dropbear_exit("signal() error");
354 } 351 }
355 if (signal(SIGSEGV, sigsegv_handler) == SIG_ERR) { 352 if (signal(SIGSEGV, sigsegv_handler) == SIG_ERR) {
356 dropbear_exit("signal() error"); 353 dropbear_exit("signal() error");
357 } 354 }
355
356 /* Now we can setup the hostkeys - needs to be after logging is on,
357 * otherwise we might end up blatting error messages to the socket */
358 loadhostkeys();
358 } 359 }
359 360
360 /* Set up listening sockets for all the requested ports */ 361 /* Set up listening sockets for all the requested ports */
361 static int listensockets(int *sock, int sockcount, int *maxfd) { 362 static int listensockets(int *sock, int sockcount, int *maxfd) {
362 363