nc: remove a bit of bloat
inetd: more NOMMU fixes rx: shrink devfsd: minor shrink vlock: shrink tcpudp: narrow down window where we have no wildcard socket parse_one_line 1015 1102 +87 init_ring - 53 +53 xzalloc_lsa - 48 +48 read_byte 51 50 -1 rearm_alarm 28 25 -3 nc_main 1028 1000 -28 initring 53 - -53 vlock_main 583 496 -87 reread_config_file 1089 991 -98 rx_main 1046 912 -134 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 1/6 up/down: 188/-404) Total: -216 bytes text data bss dec hex filename 800120 661 7428 808209 c5511 busybox_old 799796 661 7428 807885 c53cd busybox_unstripped
This commit is contained in:
@@ -339,16 +339,17 @@ int tcpudpsvd_main(int argc, char **argv)
|
||||
* 1) we have to do it before fork()
|
||||
* 2) order is important - is it right now? */
|
||||
|
||||
/* Make plain write/send work for this socket by supplying default
|
||||
/* Open new non-connected UDP socket for further clients... */
|
||||
sock = xsocket(lsa->u.sa.sa_family, SOCK_DGRAM, 0);
|
||||
setsockopt_reuseaddr(sock);
|
||||
/* Make plain write/send work for old socket by supplying default
|
||||
* destination address. This also restricts incoming packets
|
||||
* to ones coming from this remote IP. */
|
||||
xconnect(0, &remote.u.sa, sa_len);
|
||||
/* hole? at this point we have no wildcard udp socket...
|
||||
* can this cause clients to get "port unreachable" icmp?
|
||||
* Yup, time window is very small, but it exists (is it?) */
|
||||
/* Open new non-connected UDP socket for further clients */
|
||||
sock = xsocket(lsa->u.sa.sa_family, tcp ? SOCK_STREAM : SOCK_DGRAM, 0);
|
||||
setsockopt_reuseaddr(sock);
|
||||
/* ..."open new socket", continued */
|
||||
xbind(sock, &lsa->u.sa, sa_len);
|
||||
socket_want_pktinfo(sock);
|
||||
|
||||
@@ -377,7 +378,6 @@ int tcpudpsvd_main(int argc, char **argv)
|
||||
goto again;
|
||||
}
|
||||
|
||||
|
||||
if (pid != 0) {
|
||||
/* parent */
|
||||
cnum++;
|
||||
@@ -467,7 +467,7 @@ int tcpudpsvd_main(int argc, char **argv)
|
||||
|
||||
argv += 2;
|
||||
#ifdef SSLSVD
|
||||
strcpy(id, utoa(pid);
|
||||
strcpy(id, utoa(pid));
|
||||
ssl_io(0, argv);
|
||||
#else
|
||||
BB_EXECVP(argv[0], argv);
|
||||
|
||||
Reference in New Issue
Block a user