aboutsummaryrefslogtreecommitdiff
path: root/libbb
AgeCommit message (Collapse)Author
2008-09-19libbb: document that we maybe will want to understand \e somedayDenis Vlasenko
(no code changes)
2008-09-13modutils/*: rewrite by Timo Teras <timo.teras AT iki.fi>Denis Vlasenko
- a lot faster (linear algorithmic complexity, smaller memory foot print) - a lot smaller (the old code was overly complicated) - loading of aliases is now module-init-tools compliant - blacklisting is done correctly (-b option added) - module argument quoting done right - depmod now correctly generates modules.symbols and modules.alias add/remove: 16/21 grow/shrink: 4/6 up/down: 6930/-9316 Total: -2386 bytes text data bss dec hex filename 806039 592 6680 813311 c68ff busybox_old 803498 592 6676 810766 c5f0e busybox_unstripped
2008-09-11runsvd: shrink by VladimirDenis Vlasenko
*: use unified trivial signal handler function old new delta record_signo - 10 +10 process_stdin 433 443 +10 bbunpack 383 391 +8 wc_main 598 605 +7 conescape 293 296 +3 nmeter_main 670 672 +2 fallbackSort 1717 1719 +2 bb_got_signal - 1 +1 microcom_main 713 712 -1 signalled 2 - -2 pack_gzip 1661 1659 -2 evalvar 1376 1374 -2 compare_keys 737 735 -2 parse_command 1460 1456 -4 expand 1748 1744 -4 s_term 37 29 -8 s_hangup 8 - -8 fgotsig 10 - -10 find_pair 187 169 -18 signal_handler 190 170 -20 runsvdir_main 1701 1583 -118 ------------------------------------------------------------------------------ (add/remove: 2/3 grow/shrink: 6/10 up/down: 43/-199) Total: -156 bytes
2008-09-05- commentary typo fixBernhard Reutner-Fischer
2008-08-28df: add support for more options, add some coreutils 6.10 compat.Denis Vlasenko
by Bernhard Reutner-Fischer function old new delta df_main 664 795 +131 packed_usage 24812 24862 +50 make_human_readable_str 213 262 +49 static.ignored_mounts - 8 +8 static.unit_chars - 7 +7 static.zero_and_units 6 - -6 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 3/0 up/down: 245/-6) Total: 239 bytes
2008-08-23hexdump: fix SEGV in hexdump -e ""Denis Vlasenko
2008-08-20getopt32: do not return pointer to alloca() areasDenis Vlasenko
2008-08-20linedit: fix use-after-freeDenis Vlasenko
2008-08-20libbb: getopt32() should not ever touch argv[0] (even read)Denis Vlasenko
2008-08-20libbb: fix mishandling of "all argv are opts" in getopt32()Denis Vlasenko
function old new delta top_main 1100 1095 -5 getopt32 1398 1361 -37 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-42) Total: -42 bytes
2008-08-17libbb: use ptsname_r, it's smallerDenis Vlasenko
function old new delta xgetpty 91 81 -10 ptsname 33 - -33 text data bss dec hex filename 793828 592 6692 801112 c3958 busybox_old 793796 592 6660 801048 c3918 busybox_unstripped
2008-08-15mkdir: fix "uname 0222; mkdir foo/bar" caseDenis Vlasenko
(by Doug Graham <dgraham AT nortel.com>) function old new delta bb_make_directory 291 280 -11
2008-08-09optimize config_read() (by Timo Teras <timo.teras AT iki.fi>)Denis Vlasenko
function old new delta bb_get_chunk_with_continuation - 176 +176 find_pair 169 187 +18 ... process_stdin 443 433 -10 config_read 549 456 -93 bb_get_chunk_from_file 139 7 -132 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 7/7 up/down: 215/-254) Total: -39 bytes
2008-08-09grep: option to use GNU regex matching instead of POSIX one.Denis Vlasenko
This fixes problems with NULs in files being scanned, but costs +800 bytes. The same can be done to sed (TODO).
2008-08-06fix bug 4464 for real. I am dumb.Denis Vlasenko
2008-08-05*: use get_console_fd() as appropriate, and make it fail on open error -Denis Vlasenko
get_console_fd_or_die(). function old new delta get_console_fd_or_die - 163 +163 loadkmap_main 211 201 -10 loadfont_main 440 430 -10 dumpkmap_main 218 208 -10 kbd_mode_main 158 146 -12 setkeycodes_main 156 143 -13 get_console_fd 163 - -163 ------------------------------------------------------------------------------ (add/remove: 1/1 grow/shrink: 0/5 up/down: 163/-218) Total: -55 bytes
2008-08-05libbb: fix thinko in latest xrealloc_vector changeDenis Vlasenko
2008-08-05randomconfig fixesDenis Vlasenko
2008-08-05*: refactor handling of archived files. "tar f file.tar.lzma" now works too.Denis Vlasenko
function old new delta unpack_Z_stream - 1229 +1229 open_zipped - 176 +176 unpack_bz2_stream_prime - 60 +60 tar_main 642 677 +35 find_main 406 418 +12 sv_main 1222 1233 +11 decode_format_string 829 837 +8 cmp_main 641 649 +8 popstring 134 140 +6 filter_accept_list_reassign 120 125 +5 parse_and_put_prompt 800 804 +4 passwd_main 1053 1049 -4 make_new_name_gunzip 119 114 -5 rpm_main 1688 1670 -18 prepare 302 283 -19 xmalloc_open_zipped_read_close 135 61 -74 uncompress 1229 - -1229 ------------------------------------------------------------------------------ (add/remove: 3/1 grow/shrink: 8/5 up/down: 1554/-1349) Total: 205 bytes
2008-08-04modprobe: use buffering line reads (fgets) instead of reads().Denis Vlasenko
libbb: remove reads() function old new delta include_conf_file_act 961 980 +19 localcmd 282 284 +2 already_loaded 155 151 -4 in_cksum 58 53 -5 modprobe_main 1630 1624 -6 reads 129 - -129 ------------------------------------------------------------------------------ (add/remove: 0/1 grow/shrink: 2/3 up/down: 21/-144) Total: -123 bytes
2008-08-04libbb: make xrealloc_vector zero out the realloc'ed tailDenis Vlasenko
function old new delta xrealloc_vector_helper 51 76 +25 man_main 712 705 -7 act 250 234 -16 create_list 91 70 -21 getopt_main 695 664 -31 load_dep_bb 281 248 -33 fileAction 744 709 -35 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/6 up/down: 25/-143) Total: -118 bytes
2008-07-29libbb: dump: do not use uninitialized memory. close bug 4364.Denis Vlasenko
2008-07-27netstat: optional -p support by L. Gabriel Somlo <somlo AT cmu.edu>Denis Vlasenko
Without FEATURE_NETSTAT_PRG: function old new delta recursive_action 416 425 +9 tcp_do_one 420 428 +8 udp_do_one 492 499 +7 raw_do_one 472 479 +7 expand 1697 1701 +4 netstat_main 489 492 +3 unix_do_one 486 488 +2 flags 1 - -1 qgravechar 109 106 -3 net_conn_line 4 - -4 bbunpack 391 383 -8 ------------------------------------------------------------------------------ (add/remove: 0/2 grow/shrink: 7/2 up/down: 40/-16) Total: 24 bytes With FEATURE_NETSTAT_PRG: file_act - 213 +213 dir_act - 192 +192 netstat_main 489 601 +112 prg_cache_get - 50 +50 tcp_do_one 420 462 +42 udp_do_one 492 533 +41 raw_do_one 472 513 +41 unix_do_one 486 519 +33 recursive_action 416 425 +9 expand 1697 1701 +4 flags 1 - -1 qgravechar 109 106 -3 net_conn_line 4 - -4 bbunpack 391 383 -8 packed_usage 24586 24572 -14 ------------------------------------------------------------------------------ (add/remove: 3/2 grow/shrink: 7/3 up/down: 737/-30) Total: 707 bytes
2008-07-26fix several problems with config parser:Denis Vlasenko
a bug where it underflows the string a bug where it never frees parser_t struct make read_config() return 0 if parser is NULL, make config_close() accept and ignore NULL parser - eliminates many if() blocks reverse the sense of parser bit flags - negative flags are harder to grok. hexdump: revert the change to use config parser, it is BIGGER and also requires additional quirks in parser *: explicitly use PARSER_NORMAL instead of 0 function old new delta login_main 1575 1596 +21 config_close 18 29 +11 bbunpack 383 391 +8 qgravechar 106 109 +3 rtnl_tab_initialize 121 117 -4 expand 1697 1693 -4 man_main 717 712 -5 nameif_main 674 668 -6 hexdump_main 597 591 -6 read_config 217 209 -8 dnsd_main 1478 1470 -8 sysctl_main 203 189 -14 config_open2 44 25 -19 make_device 1177 1141 -36 config_read 597 549 -48 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/11 up/down: 43/-158) Total: -115 bytes
2008-07-24*: conversion to config parserDenis Vlasenko
function old new delta config_read 540 597 +57 config_open2 41 44 +3 rtnl_rtprot_initialize 70 66 -4 rtnl_rttable_initialize 78 73 -5 rtnl_rtscope_initialize 88 83 -5 rtnl_rtrealm_initialize 48 43 -5 rtnl_rtdsfield_initialize 48 43 -5 process_module 566 560 -6 bbunpack 391 383 -8 rtnl_tab_initialize 279 121 -158 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 2/8 up/down: 60/-196) Total: -136 bytes
2008-07-23s/othervise/otherwise/gDenis Vlasenko
2008-07-22another overlapping_strcpyDenis Vlasenko
2008-07-22fix all cases of strcpy on overlapping strings.Denis Vlasenko
2008-07-22- wrap overlong lines (Cristian Ionescu-Idbohrn)Bernhard Reutner-Fischer
- s/\. /. /g;# (me)
2008-07-21libbb: [x]fopen_for_{read,write} introduced and used.Denis Vlasenko
(by Valdimir) function old new delta config_open2 - 41 +41 config_read 507 542 +35 find_pair 169 187 +18 fopen_for_write - 14 +14 fopen_for_read - 14 +14 find_main 406 418 +12 xfopen_for_write - 10 +10 xfopen_for_read - 10 +10 popstring 134 140 +6 parse_inittab 396 401 +5 next_token 923 928 +5 pack_gzip 1659 1661 +2 bb__parsespent 117 119 +2 fallbackSort 1719 1717 -2 evalvar 1376 1374 -2 qrealloc 36 33 -3 ... ... ... ... singlemount 4579 4569 -10 process_stdin 443 433 -10 patch_main 1111 1101 -10 ifupdown_main 2175 2165 -10 file_action_grep 90 80 -10 uuidcache_init 649 637 -12 hush_main 797 785 -12 read_config 230 217 -13 dpkg_main 3835 3820 -15 read_line_input 3134 3110 -24 sysctl_main 232 203 -29 config_open 40 10 -30 WARN_BAD_LINE 44 - -44 login_main 1714 1575 -139 ------------------------------------------------------------------------------ (add/remove: 5/1 grow/shrink: 8/74 up/down: 174/-737) Total: -563 bytes
2008-07-21- first pass to unify/cleanup uid handling (-236b)Bernhard Reutner-Fischer
This needs further love, alot of love.. Tito?
2008-07-20libbb/parse_config.c: fix small buglet (by Vladimir)Denis Vlasenko
2008-07-20libbb: fix print_flags() [fix somehow is only in 1.11.1?)Denis Vlasenko
2008-07-20libbb: fixes to config_read() by maintainerDenis Vlasenko
sysctl: use config_read() function old new delta sysctl_main 121 232 +111 config_read 478 502 +24 parse_main 239 241 +2 sysctl_preload_file_and_exit 234 - -234 ------------------------------------------------------------------------------ (add/remove: 0/1 grow/shrink: 3/0 up/down: 137/-234) Total: -97 bytes
2008-07-19libbb: config_read() updateDenis Vlasenko
2008-07-19libbb: updated config_parse() from VladimirDenis Vlasenko
function old new delta config_read 385 460 +75 runsvdir_main 1701 1716 +15 readit 331 338 +7 passwd_main 1049 1053 +4 parse_command 1504 1507 +3 decode_format_string 822 824 +2 bb__parsespent 117 119 +2 udhcp_get_option 221 222 +1 changepath 196 194 -2 parse_inittab 400 396 -4 nameif_main 683 679 -4 make_device 1176 1172 -4 config_open 48 40 -8 expand_main 698 689 -9 readcmd 1012 1002 -10 config_free_data 37 21 -16 SynchronizeFile 683 643 -40 sleep_main 474 362 -112 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 8/10 up/down: 109/-209) Total: -100 bytes
2008-07-19test: fix parser to prefer binop over unop, as coreutils does.Denis Vlasenko
remove bogus workaround in main(). rename atrocious variables/functions. much expand testsuite. libbb: fix --help to not affect "test --help" function old new delta run_applet_no_and_exit 421 440 +19 nexpr 817 825 +8 static.no_op - 6 +6 test_main 397 257 -140 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 2/1 up/down: 104/-211) Total: -107 bytes
2008-07-18libbb: fix bb_strtol[l]'s check for "-". Hopefully closes bug 4174Denis Vlasenko
function old new delta bb_strtol 82 85 +3 handle_errors 75 66 -9 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 3/-9) Total: -6 bytes
2008-07-17pidof/killall: allow find_pid_by_name to find runningDenis Vlasenko
processes started as scripts_with_name_longer_than_15_bytes.sh closes bug 4054 (and is generally neat)
2008-07-17init: fix compile-time error; fix exiting on broken config fileDenis Vlasenko
parse_config: cosmetics
2008-07-17- fix "noreduce" flag of config_read (didn't work at all, at least for me).Bernhard Reutner-Fischer
- convert init's inittab parsing to the new config parser: function old new delta config_read 393 386 -7 static.actions 72 64 -8 .rodata 121772 121764 -8 parse_inittab 554 393 -161 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/4 up/down: 0/-184) Total: -184 bytes
2008-07-17- fix segfault in nameif with mactab fileBernhard Reutner-Fischer
(by fixing and shrink config parser) function old new delta config_free_data - 37 +37 config_open 43 48 +5 pack_gzip 1658 1660 +2 nameif_main 527 525 -2 SynchronizeFile 629 623 -6 make_device 1184 1176 -8 config_close 31 18 -13 config_read 431 393 -38 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 2/5 up/down: 44/-67) Total: -23 bytes
2008-07-17bb_strtoXXX: close bug 4174 (potential use of buf[-1])Denis Vlasenko
2008-07-16fix up callsites of config_read to check for >= 0Denis Vlasenko
2008-07-16update of config file parser from VladimirDenis Vlasenko
2008-07-16libbb: get rid of statics in dump.c; code shrinks a lot tooDenis Vlasenko
function old new delta alloc_dumper - 26 +26 hexdump_main 600 601 +1 static.done 1 - -1 static.ateof 1 - -1 bb_dump_vflag 1 - -1 static.savp 4 - -4 static.nextfs 4 - -4 static.curp 4 - -4 exitval 4 - -4 endfu 4 - -4 bb_dump_length 4 - -4 bb_dump_fshead 4 - -4 bb_dump_blocksize 4 - -4 _argv 4 - -4 bb_dump_add 365 358 -7 savaddress 8 - -8 eaddress 8 - -8 bb_dump_skip 8 - -8 address 8 - -8 bb_dump_dump 2748 2672 -76 next 538 445 -93 ------------------------------------------------------------------------------ (add/remove: 1/16 grow/shrink: 1/3 up/down: 27/-247) Total: -220 bytes text data bss dec hex filename 789458 607 6764 796829 c289d busybox_old 789309 601 6696 796606 c27be busybox_unstripped
2008-07-16od,hexdump: fix bug where xrealloc may move pointer,Denis Vlasenko
leaving other pointers dangling (bug 4104). + many style fixes in libbb/dump.c.
2008-07-15libbb: document plans to speed up line-based inputDenis Vlasenko
2008-07-15libbb: unified config parser (By Vladimir Dronnikov)Denis Vlasenko
mdev: use it function old new delta config_read - 400 +400 config_open - 43 +43 config_close - 9 +9 qrealloc 33 36 +3 compare_keys 735 737 +2 xstrtoull_range_sfx 296 295 -1 qgravechar 109 106 -3 get_address 181 178 -3 next_token 928 923 -5 sv_main 1228 1222 -6 find_main 418 406 -12 next_field 32 - -32 make_device 1269 1184 -85 ------------------------------------------------------------------------------ (add/remove: 3/1 grow/shrink: 2/7 up/down: 457/-147) Total: 310 bytes
2008-07-15libbb: experimental faster string reading routines.Denis Vlasenko