Age | Commit message (Collapse) | Author |
|
function old new delta
buffer_fill_and_print 179 196 +17
fflush_all - 9 +9
spawn 87 92 +5
rtcwake_main 455 453 -2
...
alarm_intr 93 84 -9
readcmd 1072 1062 -10
bb_ask 345 333 -12
more_main 845 832 -13
flush_stdout_stderr 42 23 -19
xfflush_stdout 27 - -27
flush_stderr 30 - -30
------------------------------------------------------------------------------
(add/remove: 1/2 grow/shrink: 2/50 up/down: 31/-397) Total: -366 bytes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
grep: support -z
find: support --mindepth
together +45 bytes
cpio: support -p (configurable, +230 bytes)
libbb: tweaks for cpio
|
|
*: s/int/pid_t where appropriate
|
|
|
|
If this breaks things, please document why!
mdev,init: use shared code for fd sanitization
function old new delta
bb_daemonize_or_rexec 155 172 +17
mdev_main 500 505 +5
init_main 907 856 -51
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/1 up/down: 22/-51) Total: -29 bytes
|
|
it trashes stack on return
|
|
function old new delta
xfork - 20 +20
msh_main 1377 1380 +3
mod_process 455 446 -9
forkexit_or_rexec 30 17 -13
expand_variables 1434 1421 -13
open_transformer 91 76 -15
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 1/4 up/down: 23/-50) Total: -27 bytes
|
|
function old new delta
time_main 1052 1285 +233
crontab_main 623 856 +233
ifupdown_main 2202 2403 +201
xvfork - 20 +20
passwd_main 1049 1053 +4
grave 1068 1066 -2
script_main 935 921 -14
vfork_or_die 20 - -20
vfork_compressor 206 175 -31
open_as_user 109 - -109
popen2 218 - -218
edit_file 910 690 -220
run_command 268 - -268
------------------------------------------------------------------------------
(add/remove: 1/4 grow/shrink: 4/4 up/down: 691/-882) Total: -191 bytes
|
|
text data bss dec hex filename
808035 611 6868 815514 c719a busybox_old
804472 611 6868 811951 c63af busybox_unstripped
|
|
|
|
|
|
some code reduction along the way.
function old new delta
run_list 1971 1981 +10
run_nofork_applet_prime 181 182 +1
unsetcmd 97 96 -1
delete_cmd_entry 54 53 -1
describe_command 399 397 -2
cmdlookup 152 150 -2
evaltreenr 602 599 -3
evaltree 602 599 -3
clearcmdentry 101 98 -3
cdcmd 675 672 -3
hashcmd 305 301 -4
find_command 933 910 -23
evalcommand 1371 1229 -142
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/11 up/down: 11/-187) Total: -176 bytes
|
|
|
|
|
|
|
|
*: use more approproate (shorter) versions of wait()
function old new delta
safe_waitpid - 48 +48
wait_any_nohang - 17 +17
send_tree 365 369 +4
processorstop 432 435 +3
text_yank 110 108 -2
make_human_readable_str 202 200 -2
crond_main 1368 1366 -2
handle_sigchld 49 43 -6
reapchild 166 159 -7
custom 260 250 -10
checkscript 191 177 -14
wait_nohang 17 - -17
wait_pid 43 - -43
------------------------------------------------------------------------------
(add/remove: 2/2 grow/shrink: 2/7 up/down: 72/-103) Total: -31 bytes
|
|
text data bss dec hex filename
775923 929 9100 785952 bfe20 busybox_old
775565 929 9100 785594 bfcba busybox_unstripped
|
|
Should be a big win for libbusybox. busybox wins too:
text data bss dec hex filename
776524 929 9100 786553 c0079 busybox_old
775903 929 9100 785932 bfe0c busybox_unstripped
|
|
|
|
263 bytes saved.
|
|
|
|
|
|
init_main 929 920 -9
bb_daemonize_or_rexec 145 127 -18
|
|
# size busybox_old busybox_unstripped
text data bss dec hex filename
680095 2704 15648 698447 aa84f busybox_old
680099 2704 15648 698451 aa853 busybox_unstripped
|
|
was eating all remaining input, potentially megabytes.
nofork: save/restore die_jmp too
nofork: use -2222 instead of -111 as "special" return valur for zero
(-111 is used by some applets. -2222 won't fit in exitcode and thus safer)
|
|
|
|
|
|
|
|
set/save/restore more shared global variables whan call one applet from another
|
|
|
|
"#ifndef BB_NOMMU" is a double negative
|
|
|
|
FEATURE_SH_STANDALONE_SHELL => FEATURE_SH_STANDALONE
FEATURE_EXEC_PREFER_APPLETS => FEATURE_PREFER_APPLETS
Make SH_STANDALONE depend on PREFER_APPLETS.
getopt.c: more randomconfig-induced fixes
|
|
no forking anymore, bunzip2 unpack routine now does all it in memory.
|
|
rename sllep_and_die -> xfunc_die
make fflush_stdout_and_exit NOFORK-safe
fix some buglets found by randomconfig
|
|
use it for making NOFORK more practical.
touch: make it a NOFORK applet
|
|
|
|
|
|
find: use NOFORK/NOEXEC; small -exec buglet also eliminated
vfork_daemon_rexec: honor PREFER_APPLETS
echo: small size improvements
find -exec echo {} \; with PREFER_APPLETS=y runs 4 times faster
|
|
fsck: fix bad English in a comment
|
|
TODO_config_nommu documents what I managed to compile so far
(yay! msh works! cool). inetd, telnetd, httpd still do not compile. TODO
Also make fork(), daemon() produce warnings on compile stage
(in addition to erros on link stage).
|
|
and easier to use. Doesn't compile - need two more commits.
|
|
option for every affected applet (and dnsd, for example, don't have one).
Thus rework re-exec support to not require it. Code got smaller too.
|
|
(will close all fd's > 2 on daemonization now)
getty: fix "getty -" support, and also do not try to chown/chmod "-"
telnetd: fix "lost ctty" bug
Yet another attempt on saner function names:
bb_sanitize_server_stdio(0/1) -> bb_sanitize_stdio() + bb_daemonize();
|
|
last xcalloc replaced by xzalloc
|
|
httpd: ifdef CONFIG -> if ENABLE (shorted, catched typos)
|