aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-02-07dd: add optional support for status=noxfer/noneAri Sundholm
While at it, added 'B' number suffixes, upstream compat function old new delta dd_main 1469 1543 +74 dd_suffixes 88 112 +24 packed_usage 30156 30176 +20 dd_output_status 372 388 +16 static.status_words - 13 +13 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 4/0 up/down: 147/0) Total: 147 bytes Signed-off-by: Ari Sundholm <ari@tuxera.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-05ash: fix a SEGV case in an invalid heredocDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-05deluser: implement --remove-homeDenys Vlasenko
function old new delta deluser_main 308 355 +47 packed_usage 30149 30156 +7 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 2/0 up/down: 54/0) Total: 54 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-04fstrim: fix help textDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-04route: fix bogus read error when route table is emptyDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-03route: improve -A inet6Denys Vlasenko
Upstream route command shows non-up routes, it shows reject and nonexthop flags. And we had "ref" and "use" values mixed up... function old new delta flagvals 32 44 +12 flagchars 9 12 +3 INET_setroute 767 768 +1 INET6_setroute 495 496 +1 set_flags 43 39 -4 flags_ipvx 16 8 -8 route_main 632 623 -9 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/3 up/down: 17/-21) Total: -4 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-03gzip: trivial code shrink -5 bytesDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-03ifconfig: fix double free fatal error in INET_sprintDenys Vlasenko
Based on the patch by Zheng Junling <zhengjunling@huawei.com> and Chen Gang <cg.chen@huawei.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-03libbb: make INET[6]_rresolve use sockaddr2{host,dotted}_noportDenys Vlasenko
function old new delta INET_rresolve 274 214 -60 INET6_rresolve 168 85 -83 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-02gzip: speed up and shrink put_16bit()Denys Vlasenko
function old new delta put_16bit 104 98 -6 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-02gzip: do not store timestamp in gzip headerRich Felker
Storing the original file's modification time in the output file is harmful (precludes deterministic results) and unlike official gzip, the busybox version provides no way to suppress this behavior; the -n option is silently ignored. Rather than trying to make -n work, this patch just removes the timestamp-storing functionality. It should be considered deprecated anyway; it's not Y2038-safe and gunzip ignores it by default. Per RFC 1952, 0 is the correct value to store to indicate that there is no timestamp. Signed-off-by: Rich Felker <dalias@libc.org> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-02platform.h: enable mempcpy for FreeBSDDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-30ubiattach: add option -OMicke Prag
Some images do not have the default VID offset. The option -O must be used to attach such images. Signed-off-by: Micke Prag <micke.prag@telldus.se> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-30telnetd: we only need CONFIG_UNIX98_PTYS from the Linux kernelMartin Kaiser
(re-sending this as it got ignored completey and the format of the previous mail was probably not correct - please let me know if there's anything else I can do to get this trivial fix applied) for telnetd to work, we only need CONFIG_UNIX98_PTYS to be enabled in the Linux kernel - DEVPTS_FS has been obsolete for some time Signed-off-by: Martin Kaiser <lists@kaiser.cx> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-30dpkg: update supported compression methodsDenys Vlasenko
Based on a patch by Ron Yorston <rmy@tigress.co.uk> function old new delta get_header_tar_xz - 60 +60 filter_accept_list_reassign 128 188 +60 unpack_package 585 621 +36 init_archive_deb_control 52 76 +24 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 3/0 up/down: 180/0) Total: 180 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-29platform.h: mempcpy needs <string.h>Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-29ntpd: get rid of G.initial_poll_completeDenys Vlasenko
This speeds up syncing - now happens only just two replies from a peer. Especially useful for "ntpd -q". Shouldn't have ill effects: if we chose a bad peer, we will discover it later and switch to another one. The code is even smaller this way. Suggested by Miroslav Lichvar <mlichvar@redhat.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-27dhcpd: fix an improper widening conversionDenys Vlasenko
We wanted to detect when tv_sec = unsigned1 - unsigned2 underflows by looking at tv_sec's sign. But if tv_sec is long and it is wider than unsigned, we get unsigned -> long conversion which is in this case never negative. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-26ftpd: prevent zombies. closes 7832Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-25platform.h: add compat mempcpyDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-24depmod: simple memory optimizationDenys Vlasenko
function old new delta filename2modname 67 86 +19 parse_module 374 351 -23 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-24trim extra newlines in help textsDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-19modprobe: fix modprobe -r and parsing of /etc/modprobe.dNatanael Copa
This fixes a regression introduced with commit 78854520 (modprobe: revert checking for /, stop doing basename() on modprobe args, 2015-01-01) that broke modprobe options stored in /etc/modprobe.conf and /etc/modprobe.d/*.conf. This also fixes modprobe -r Signed-off-by: Natanael Copa <ncopa@alpinelinux.org> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-15modprobe: fix "modprobe devname:snd/timer" case (alias with a slash)Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-15modprobe: fix recent breakage: modules.dep reading code needs to strip dirnameDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-11modprobe-small: code shrinkDenys Vlasenko
function old new delta pathname_matches_modname 80 42 -38 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-11modprobe-small: fix recent breakage: modprobe -r was using full pathDenys Vlasenko
"modprobe -r MODNAME", after it found the full module pathname, should strip dirpath before trying to remove the module. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-11diff: fix a bug in diffing against stdin. Closes 7784Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-07vi: fix reading of file after last lineRon Yorston
If the :r command is used to read a file after the last line of the buffer the last line of the buffer and the first line of the file are joined. An extra blank line appears at the end of the buffer. file 1 file 1 file 1file 2 file 2 file 2 ~ ~ The insertion point is normally at the start of the line following the specified line. When the specified line is the last one the next_line function baulks at moving to the non-existent following line. Signed-off-by: Ron Yorston <rmy@tigress.co.uk> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-07vi: failure to open file is not an error when initialising bufferRon Yorston
Commit 32afd3a introduced these regressions on the master branch: Starting vi with no filename on the command line gives the status message "'(null)' Bad address" instead of "- No file 1/1 100%". Starting vi with a non-existent file on the command line gives the status message "'new.txt' No such file or directory" instead of "- new.txt 1/1 100%" Signed-off-by: Ron Yorston <rmy@tigress.co.uk> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-07depmod: fix recent breakage in modules.dep generationDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-06libpwdgrp: line counting in error meesages is broken, remove itTito Ragusa
Signed-off-by: Tito Ragusa <farmatito@tiscali.it> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05swaponoff: add support for -eRené Rhéaume
Signed-off-by: René Rhéaume <rene.rheaume@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05mpstat: code shrinkDenys Vlasenko
function old new delta get_uptime 134 129 -5 get_irqs_from_stat 110 103 -7 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05free: handle "cached" value tooGuillermo Rodriguez
function old new delta free_main 356 481 +125 Signed-off-by: Guillermo Rodriguez <guille.rodriguez@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05libbb: code shrink by factoring out common update_utmp_DEAD_PROCESSDenys Vlasenko
function old new delta update_utmp_DEAD_PROCESS - 17 +17 telnetd_main 1685 1674 -11 mark_terminated 56 45 -11 handle_sigchld 74 63 -11 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05deleting unused ntpd_simple.cDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-05libpwdgrp: fixes suggested by Tito, comment tweaksDenys Vlasenko
function old new delta bb_internal_getpwent_r 100 121 +21 parse_common 202 203 +1 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-04ntpd: relicense ntpd applet to ISC-style licenseAdam Tkac
OpenNTPd is licensed under ISC-style license so it's good idea to keep ntpd applet under same license to avoid mess, instead of having our changes to be under GPL. Names of original code's authors are added. Signed-off-by: Adam Tkac <vonsch@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-04libpwdgrp: another code shrinkDenys Vlasenko
function old new delta massage_data_for_r_func - 110 +110 bb_internal_getpwent_r 173 100 -73 getXXnam_r 176 95 -81 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 0/2 up/down: 110/-154) Total: -44 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-04libpwdgrp: code shrinkDenys Vlasenko
function old new delta parse_common 206 205 -1 getgrouplist_internal 229 225 -4 bb_internal_getpwent_r 182 173 -9 getXXnam 232 222 -10 getXXnam_r 216 176 -40 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/5 up/down: 0/-64) Total: -64 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: getgrXXX: empty string is not a member name, do not store itDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03fix a SEGV in previous commitDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: fix counting of commas in group listDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: store getXXnam result in a single malloc blockDenys Vlasenko
This saves a bit of memory but more importantly, allows to create xmalloc_getpwnam() API where result can be deleted simply using free(). function old new delta getXXnam 134 173 +39 parse_common 188 212 +24 convert_to_struct 277 290 +13 get_S 90 88 -2 tokenize 129 126 -3 bb_internal_getpwent_r 175 172 -3 getXXnam_r 208 198 -10 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 3/4 up/down: 76/-18) Total: 58 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: make db->def[] one byte shorterDenys Vlasenko
In the future I will need another uint8_t, want to fit it w/o using another word on 32 bits. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: use a better estimate of max struct sizeDenys Vlasenko
Previous code's trick with bitwise OR was giving this on 32-bit x86: sizeof(struct passwd):28 sizeof(struct group):16 sizeof(struct spwd):36 sizeof(struct_result):60 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: reinstate Tito's optional atexit freeingDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: fix a memory leak in getXXnam (we did not save address of string buf)Denys Vlasenko
function old new delta convert_to_struct 261 269 +8 const_sp_db 20 24 +4 const_pw_db 20 24 +4 const_gr_db 20 24 +4 tokenize 144 147 +3 parse_common 185 188 +3 get_S 82 85 +3 bb_internal_getpwent_r 188 185 -3 gr_off 4 - -4 getXXnam 171 165 -6 pw_off 7 - -7 getgrouplist_internal 237 229 -8 getXXnam_r 215 207 -8 sp_off 9 - -9 ------------------------------------------------------------------------------ (add/remove: 0/3 grow/shrink: 7/4 up/down: 29/-45) Total: -16 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-01-03libpwdgrp: tweak comments, replace one xmalloc with xzallocDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>