74324c8666
Audit bb_common_bufsiz usage, add script which looks for misuse.
...
tr: stop using globals needlessly.
code: -103 bytes
2007-06-04 10:16:52 +00:00
9a7d38fe24
delete tons of extra #includes
2007-05-31 22:42:12 +00:00
fad2b86c9e
use "glibc errno" trick not only for ash, but for entire busybox
...
(add/remove: 1/1 grow/shrink: 37/37 up/down: 139/-228) Total: -89 bytes
2007-05-31 22:16:38 +00:00
b6adbf1be2
usage.c: remove reference to busybox.h
...
*: s/include "busybox.h"/include "libbb.h"
2007-05-26 19:00:18 +00:00
d4728145e3
run_parts: do not check path portion of a name for "bad chars".
...
Needed for ifupdown. Patch by "Gabriel L. Somlo" <somlo@cmu.edu >
2007-04-29 23:38:12 +00:00
51742f4bb0
style fixes. No code changes
2007-04-12 00:32:05 +00:00
8d9f495d68
getopt32: fix llist_t options ordering. llist_rev is not unused.
...
function old new delta
tar_main 705 695 -10
sort_main 928 918 -10
decode_format_string 886 876 -10
run_parts_main 197 185 -12
ps_main 513 500 -13
wget_main 2764 2750 -14
awk_main 1014 1000 -14
od_main 2886 2866 -20
llist_rev 25 - -25
------------------------------------------------------------------------------
(add/remove: 0/1 grow/shrink: 0/8 up/down: 0/-128) Total: -128 bytes
2007-04-08 15:08:42 +00:00
bbd695d801
find: fix handling of -prune
...
recursive_actions: uppercase flag constants
2007-04-08 10:52:28 +00:00
3e816c1252
- fold recurse, depthFirst and dereference params into one param flags.
...
Minor size improvement (-16b for size, -24b according to bloat-o-meter).
2007-03-29 10:30:50 +00:00
c7d4b98cbd
run_parts: I was wrong, NULL termination is already done because
...
G is pre-initialized to 0.
2007-03-28 22:05:38 +00:00
45cd089df1
run_parts: NULL-terminate list of arguments; fix perror/error usage
2007-03-28 22:04:04 +00:00
b7cffd4bed
- rewrite run-parts
...
text data bss dec hex filename
1029 0 0 1029 405 debianutils/run_parts.o-old
478 0 0 478 1de debianutils/run_parts.o-new-bare
600 0 0 600 258 debianutils/run_parts.o-new-full
bare, i.e. without long opts and fancy stuff
./scripts/bloat-o-meter bb_old busybox_unstripped function old new delta
act - 215 +215
run_parts_main 216 201 -15
valid_name 50 - -50
runparts_long_options 64 - -64
.rodata 124323 124163 -160
run_parts 513 - -513
------------------------------------------------------------------------------
(add/remove: 1/3 grow/shrink: 0/2 up/down: 215/-802) Total: -587 bytes
2007-03-28 20:35:13 +00:00
5a142025d3
move everything to new NOMMU helpers, except udhcp
2007-03-26 13:20:54 +00:00
cce38586ae
start_stop_daemon: add -chuid support
2007-02-26 22:47:42 +00:00
6ca0444420
syslogd: fix "readpath bug" by using readlink instead
...
libbb: rename xgetcwd and xreadlink
2007-02-11 16:19:28 +00:00
06af216528
suppress warnings about easch <applet>_main() having
...
no preceding prototype
2007-02-03 17:28:39 +00:00
9d938732d0
fix which-uses-default-path
2007-01-28 15:31:19 +00:00
9af7c9d6b6
openvt,getty,vfork_daemon_rexec,mount: tighten up fd cleanup code
...
(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();
2007-01-19 21:19:35 +00:00
9a44c4f91c
bb_xget[pw/gr]nam were horribly misnamed - fixed.
...
uidgid_get -> get_uidgid, add additional param
(numeric_ok). Make chown use it.
chown: fix "chown user: ...."
install: fix incorrect use of bb_xget[pw/gr]nam
2006-12-28 05:44:47 +00:00
b8c77b5b25
start_stop_daemon: make code a bit more readable
2006-12-17 19:43:10 +00:00
b131b271a0
start_stop_daemon: fix bug where any program name was "matching"
...
processes for which readlink(/proc/N/exe) fails
2006-12-17 17:30:01 +00:00
079f8afa0a
style cleanup: return(a) -> return a, part 1
2006-11-27 16:49:31 +00:00
e5667c1cfe
Closing bug 730. libbb run_parts is using scandir (a GNUism),
...
and it is used only by run_parts applet, so move it there.
Also saved ~30 bytes (prolly gcc autoinlining...).
2006-11-26 20:13:39 +00:00
89f0b3486d
rodata cleanup. "unable to" == "cannot". -300 bytes
2006-11-18 22:04:09 +00:00
61126ab30a
small fixes: using fd-based io instead of FILE*-based,
...
missed O_TRUNC, etc
2006-11-18 22:03:26 +00:00
f0ed376eda
remove bb_printf and the like
2006-10-26 23:21:47 +00:00
456fa6c0b1
readlink: do not emit errors if file doesnt not exist / not a link
...
getopt32: add =N support
2006-10-20 18:36:55 +00:00
f6f43df60b
ifupdown: stop emitting annoying/misleading error messages.
...
Patch by Gabriel Somlo <somlo at cmu.edu>
2006-10-11 22:16:56 +00:00
1ac42bf66e
- add option -t
...
mkinitrd and mkinitramfs both require -t.
2006-10-10 15:28:41 +00:00
ca3c981c07
start_stop_daemon: add -N <nice> compat
...
[re]nice: add support for -nNNN w/o spaces, -NNN (nice only),
simplified code
2006-10-08 23:36:17 +00:00
1385899416
attempt to regularize atoi mess.
2006-10-08 12:49:22 +00:00
01c27fc5ac
which: -84 bytes
2006-10-05 21:10:53 +00:00
7d219aab70
build system overhaul
2006-10-05 10:17:08 +00:00
67b23e6043
getopt_ulflags -> getopt32.
...
It is impossible to formulate sane ABI based on
size of ulong because it can be 32-bit or 64-bit.
Basically it means that you cannot portably use
more that 32 option chars in one call anyway...
Make it explicit.
2006-10-03 21:00:06 +00:00
9213a9e0f2
whitespace cleanup
2006-09-17 16:28:10 +00:00
7fee0c4357
- fix copy'n paste errors that got introduced when switching to the shorter boilerplate.
...
No object code changes.
2006-09-13 16:39:19 +00:00
8cedabaee0
Patch from Natanael Copa to make start-stop-daemon just use readlink and
...
strcmp to check if a program is already running.
2006-09-04 18:59:39 +00:00
8479063667
Bugfix from Jason Schoon: send the right signal with -s.
2006-08-28 20:30:27 +00:00
d921b2ecc0
Remove bb_ prefixes from xfuncs.c (and a few other places), consolidate
...
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only
had one user), clean up lots of #includes... General cleanup pass. What I've
been doing for the last couple days.
And it conflicts! I've removed httpd.c from this checkin due to somebody else
touching that file. It builds for me. I have to catch a bus. (Now you know
why I'm looking forward to Mercurial.)
2006-08-03 15:41:12 +00:00
f86a5ba510
Remove unnecessary consts.
2006-07-19 21:45:30 +00:00
fc2aea1a76
Rearrange order of type qualifiers.
2006-07-18 11:33:44 +00:00
f0623a2c98
Patch from Thaddeus Ternes, adding chuid to start-stop-daemon.
2006-07-17 00:35:07 +00:00
66e3a222cd
- minor shrinkage
2006-06-14 16:17:50 +00:00
2f6a317944
- fix stupid typo from last checkin
2006-06-12 14:34:01 +00:00
a926f8e50a
- add fancy mode to start-stop-daemon to support --oknodo and --verbose
2006-06-11 17:24:01 +00:00
e15d7573a1
- move #include busybox.h to the very top so we pull in the config
...
and eventual platform specific includes in early.
2006-06-02 20:56:16 +00:00
01d23ade57
- add central knob to turn off getopt_long everywhere. EXPERIMENTAL!
...
Adds "Enable getopt long" under "General options", default y.
Send patches to fix getopt_ulflags and run_parts.c if you turn this off..
See http://busybox.net/lists/busybox/2006-May/021828.html for a start to run-parts
2006-05-26 20:19:22 +00:00
b1629b1b2a
- remove emacs layout block as suggested by Robert P.J. Day
...
- use shorter boilerplate while at it
2006-05-19 19:29:19 +00:00
5371a953ca
The gnu extension to have realpath() malloc its buffer when handed a NULL
...
isn't implemented in uClibc, so we can't use it.
2006-05-17 04:09:14 +00:00
39440e520c
pull Rules.mak from top_srcdir as pointed out by Robert P. J. Day on the mailing list
2006-05-13 02:33:09 +00:00