Rob Landley
425e7584a4
Patch from Rich Felker to make ls use libc's qsort.
2006-05-03 20:22:03 +00:00
Rob Landley
c5598177bc
Patch from Jason Schoon to add optional SIGUSR1 support to dd.
2006-05-02 22:44:04 +00:00
Rob Landley
2631486f1b
Patch from Shaun Jackman:
...
ls has an ugly bug. ls uses an array of pointers, the elements of
which are all in a linked list. To free the elements, instead of
freeing all the elements in the array, array[0..nelements], it frees
by iterating the linked list starting at array[0], which it assumes is
the head of the list. Unfortunately, ls also sorts the array! So,
array[0] is no longer the head, but somewhere in the middle of the
linked list. This patch fixes this bug, and also adds an
ENABLE_FEATURE_CLEAN_UP stanza.
2006-05-02 19:46:52 +00:00
Rob Landley
d5b9428bb6
Re-wordwrap the new tests, and fix seq.c to pass them.
2006-04-27 22:36:32 +00:00
Rob Landley
5fe8d5b9c5
Convert a chunk of usage.h to USE_ and SKIP_ (more to do there), and fix a
...
DEFALT typo in du while I was there.
2006-04-25 22:40:53 +00:00
Rob Landley
998dbee6d9
Patch from Jean Wolter:
...
it looks like the introduced support for character classes and
equivalence classes is not correct. The attached patch tries to fix
some symptoms and tries to make tr behave like gnu tr for the added
test cases. The patch
- removes if clauses with side effects
- fixes handling of buffer pointer (strcat added characters to the
buffer without increasing the buffer pointer)
- re-arranges character classes to match ASCII order
regards,
Jean
2006-04-19 22:22:06 +00:00
Rob Landley
856489b63c
New applet cksum, from Rob Sullivan.
2006-04-18 20:57:28 +00:00
Rob Landley
e4386342b4
Simplify the GPL boilerplate.
2006-04-18 20:41:51 +00:00
Bernhard Reutner-Fischer
18260d5099
- typo: s/derefernce/dereference/g
...
Thanks to P.J. Day.
2006-04-18 14:17:49 +00:00
Rob Landley
0edbad1a7c
Glenn gave permission for GPLv2 "or later".
2006-04-17 22:49:30 +00:00
Mike Frysinger
0436b9f482
use strchr() not index()
2006-04-16 05:54:31 +00:00
Rob Landley
2ec922eed5
Patch from Robert P Day: let menuconfig indent stuff for us, we don't have
...
to do it in Config.in.
2006-04-13 23:22:16 +00:00
Bernhard Reutner-Fischer
c2cb0f32b4
- patch from Denis Vlasenko to add and use bb_xopen3()
2006-04-13 12:45:04 +00:00
Bernhard Reutner-Fischer
d9cf7ac781
- patch from Denis Vlasenko to add and use bb_xchdir()
2006-04-12 18:39:58 +00:00
Bernhard Reutner-Fischer
fc5f318896
- use C99 %j format to print intmax.
...
Closes bugs #802 and #743
2006-04-12 08:03:11 +00:00
Bernhard Reutner-Fischer
cb44816ba3
- add and use bb_opendir(), bb_xopendir().
...
text data bss dec hex filename
889445 9392 1035784 1934621 1d851d busybox.gcc-4.2.orig
889297 9392 1035784 1934473 1d8489 busybox.gcc-4.2
889009 9820 1037860 1936689 1d8d31 busybox.gcc-4.1.orig
888817 9820 1037860 1936497 1d8c71 busybox.gcc-4.1
2006-04-12 07:35:12 +00:00
Rob Landley
998f449375
We use -funsigned-char now, so having a separate RESERVE_CONFIG_UBUFFER is
...
a bit silly. Wean of that where it currently makes no difference...
2006-04-10 16:40:47 +00:00
Bernhard Reutner-Fischer
bc14214018
- patch from Rob Sullivan to add support for -L
2006-04-06 16:07:08 +00:00
Bernhard Reutner-Fischer
5fb0fecc1f
- shrink it a little bit and make it buildable with gcc-2.95
...
text data bss dec hex filename
7332 4 92 7428 1d04 diff.o-gcc-4.2-HEAD.orig
7185 4 92 7281 1c71 diff.o-gcc-4.2-HEAD.new
7336 4 92 7432 1d08 diff.o-gcc-4.1-HEAD.orig
7148 4 92 7244 1c4c diff.o-gcc-4.1-HEAD.new
7485 4 92 7581 1d9d diff.o-gcc-4.0.orig
7318 4 92 7414 1cf6 diff.o-gcc-4.0.new
7511 4 92 7607 1db7 diff.o-gcc-3.4.orig
7252 4 92 7348 1cb4 diff.o-gcc-3.4.new
8214 4 92 8310 2076 diff.o-gcc-3.3.orig
7882 4 92 7978 1f2a diff.o-gcc-3.3.new
- - - - - diff.o-gcc-2.95.orig
8238 8 88 8334 208e diff.o-gcc-2.95.new
2006-04-06 11:28:19 +00:00
Bernhard Reutner-Fischer
cc4003f778
- remove unused args.
...
text data bss dec hex filename
7353 4 92 7449 1d19 coreutils/diff.o-gcc-4.2.oorig
7332 4 92 7428 1d04 coreutils/diff.o
2006-04-06 08:23:11 +00:00
Bernhard Reutner-Fischer
693a93608a
- move code around to avoid the need for the prototypes.
2006-04-06 08:15:24 +00:00
Bernhard Reutner-Fischer
8f7d389700
- new applet diff. Rob Sullivan writes:
...
Here's my attempt at a mini diff applet - it's adapted from the code at
http://www.openbsd.org/cgi-bin/cvsweb/src/usr.bin/diff/ , and only supports
unified diffs.
I've busyboxified everything to a reasonable degree, so I think the code is
suitable enough to be included, but there's still a fair bit of cleaning up
to be done.
2006-04-06 08:11:08 +00:00
Bernhard Reutner-Fischer
e11a01cc34
- include inttypes.h as pointed out by Jason Schoon.
...
- use shorter boilerplate and switch to USE_FEATURE_STAT_FORMAT while at it.
2006-04-05 17:19:37 +00:00
Bernhard Reutner-Fischer
465874f3a3
- use proper macros to print intmax_t.
...
PRIuMAX and PRIxMAX are defined in inttypes depending on the wordsize.
2006-04-05 14:57:59 +00:00
Rob Landley
e104d5fdcb
Some tests were always true. We need comm.tests...
2006-04-04 19:26:37 +00:00
Bernhard Reutner-Fischer
101a470068
- make append_option and multiconvert static.
2006-04-03 15:46:14 +00:00
Bernhard Reutner-Fischer
a1bccc0ba8
- typos: s/compatability/compatibility/g;s/compatable/compatible/g;
2006-04-02 20:17:55 +00:00
Bernhard Reutner-Fischer
d409c3a2f7
- Rich Felker writes: fix invalid printf format strings
...
http://busybox.net/lists/busybox/2006-March/019568.html
text data bss dec hex filename
900619 10316 1038724 1949659 1dbfdb busybox.oorig
900603 10316 1038724 1949643 1dbfcb busybox
2006-03-29 22:34:47 +00:00
Rob Landley
c370ea89fa
Turn #if 0 into a comment.
2006-03-27 17:00:11 +00:00
Mike Frysinger
948a09d6f2
dont printf arguments given by user for security sanity
2006-03-23 02:07:20 +00:00
Rob Landley
2324a7c9e5
Fix "seq 1 1".
2006-03-22 17:11:44 +00:00
Rob Landley
cebea726e8
Another header suggestion from Shaun Jackman.
2006-03-22 00:46:36 +00:00
Bernhard Reutner-Fischer
99a072d524
- tito writes: this patch fixes some comments in dos2unix that are wrong
...
or that reports non existent features (that i've ripped out...)
2006-03-18 23:05:37 +00:00
Rob Landley
330ac853e3
Tito shrank dos2unix.
2006-03-14 21:49:18 +00:00
Bernhard Reutner-Fischer
df10094870
- revert back to r14406
2006-03-13 19:04:00 +00:00
Rob Landley
c5b1d4d6b1
Patch from Denis Vlasenko to add xstat() and use it.
2006-03-13 15:45:16 +00:00
Rob Landley
e01d746fe9
Cleanup patch from tito.
2006-03-12 19:26:01 +00:00
Rob Landley
1c60d9762e
Size reduction by Tito.
2006-03-11 18:22:35 +00:00
Rob Landley
bc68cd14cc
Patch from Denis Vlasenko turning static const int (which gets emitted into
...
the busybox binary) into enums (which don't).
2006-03-10 19:22:06 +00:00
Bernhard Reutner-Fischer
07a79e75f5
- backout using features which are not available with the previous stable
...
version of make (3.71.1).
2006-03-09 09:03:37 +00:00
Rob Landley
dfba741457
Robert P. Day removed 8 gazillion occurrences of "extern" on function
...
definitions. (That should only be on prototypes.)
2006-03-06 20:47:33 +00:00
Rob Landley
1f5e25bf3e
Walt Wimer noticed that mknod couldn't handle major or minor > 255. Now our
...
limit checking autodetects what the system supports (at compile time).
2006-03-06 19:31:39 +00:00
Bernhard Reutner-Fischer
e3ec99de82
- remove unused lists *-m
2006-03-02 18:23:13 +00:00
Bernhard Reutner-Fischer
022eb311d5
- use absolute path for top_builddir and top_srcdir.
...
Fixes make trying to include the very same file in an endless loop.
2006-03-02 17:33:25 +00:00
Bernhard Reutner-Fischer
5d26126b9e
- fixes parallel builds (make -j)
...
- use less resources for the buildsystem itself
2006-03-01 22:54:48 +00:00
Rob Landley
08abe64d91
Selinux fix from Jan Kiszka.
2006-03-01 20:48:44 +00:00
"Vladimir N. Oleynik"
5c2b238b3a
more busybox's style: close bug 745
2006-02-28 10:15:42 +00:00
Rob Landley
2b26fd5570
A few changes falling out from the effort to make sed handle embedded NUL bytes.
...
Checking in to reduce the diff between my tree and svn...
2006-02-24 02:30:39 +00:00
Rob Landley
73a20f3551
"sed 2 -2 10" was very unhappy. Made the thing bigger fixing it,
...
fiddled a bit to get the size back down as much as I could...
2006-02-23 19:54:48 +00:00
Rob Landley
0a7c8ef6e2
Patch from Denis Vlasenko to constify things and fix a few typos.
2006-02-22 17:01:00 +00:00
Rob Landley
d6e14d8bee
Don't build directory libraries unless we're building an applet that needs it.
...
Cherry-picked from Devin Bayer's big MacOS X patch.
2006-02-21 19:11:35 +00:00
Rob Landley
5cf7c2df66
Patch from Devin Bayer to split up hash_fd.c into md5.c and sha1.c. (I tweaked
...
md5_sha1_sum.c to convert some #ifdef CONFIG to if(ENABLE).)
2006-02-21 06:44:43 +00:00
Rob Landley
c5789a6e23
Walter Harms added -D to date, and I did a code cleanup while I was in the
...
area. Probably broke something...
2006-02-21 05:06:42 +00:00
Mike Frysinger
dfd902b7ff
rfelker writes in Bug 736: stty.c includes unneeded, obsolete header memory.h
2006-02-19 22:43:58 +00:00
Mike Frysinger
4b33f7aa41
rfelker writes in Bug 734: Nothing from err.h is used, but cal.c includes it, breaking compile on systems lacking this function.
2006-02-19 22:41:41 +00:00
Rob Landley
02794e1516
Fix bug 674: sum's block count should always round up.
2006-02-14 17:47:05 +00:00
Rob Landley
30a6bba65f
Bug 677: there are apparently still people using telnet.
2006-02-06 02:49:45 +00:00
Mike Frysinger
b38673fb9f
make the build system puuuuuuuuuuurty
2006-02-02 01:41:53 +00:00
"Vladimir N. Oleynik"
87be316149
more better for me signed<->unsigned and the const keyword usage
2006-01-31 14:25:52 +00:00
"Vladimir N. Oleynik"
57545c810a
avoid signed<->unsigned warning
2006-01-31 12:06:57 +00:00
Eric Andersen
5e678873f9
clean up yet more annoying signed/unsigned mismatches and fixup
...
yet more incorrect types
2006-01-30 19:48:23 +00:00
Bernhard Reutner-Fischer
4bf31272ff
- very minor tweak: save 1 byte.
...
statistics:
text data bss dec hex filename
867 0 12 879 36f fold.o.oorig.gcc-3.3
843 0 12 855 357 fold.o.oorig.gcc-3.4
780 0 12 792 318 fold.o.oorig.gcc-4.0
761 0 12 773 305 fold.o.oorig.gcc-4.1-HEAD
761 0 12 773 305 fold.o.oorig.gcc-4.2-HEAD
866 0 12 878 36e fold.o.gcc-3.3
842 0 12 854 356 fold.o.gcc-3.4
779 0 12 791 317 fold.o.gcc-4.0
760 0 12 772 304 fold.o.gcc-4.1-HEAD
760 0 12 772 304 fold.o.gcc-4.2-HEAD
2006-01-30 17:41:06 +00:00
Bernhard Reutner-Fischer
20f4000086
- add some ATTRIBUTE_UNUSED.
...
- use shorter boilerplate while at it.
2006-01-30 17:17:14 +00:00
"Vladimir N. Oleynik"
676b15e067
removed warning "comparison between signed and unsigned".
2006-01-30 13:47:19 +00:00
"Vladimir N. Oleynik"
9b9a920eef
removed warning "comparison between signed and unsigned". Reduced size
2006-01-30 12:23:46 +00:00
"Vladimir N. Oleynik"
e75b41d990
support GNU suffixes for fancy mode: b(512), k(1024) and m(1024*1024)
2006-01-30 11:15:11 +00:00
"Vladimir N. Oleynik"
b1fd52e0b7
remove outdated and do not corected comment. Use bb_xasprintf instead xmalloc+set+set+strcpy.
2006-01-30 10:49:14 +00:00
Rob Landley
f8fd4db92f
Move SUSv2 obsolete feature disabling to debug menu, invert meaning of
...
symbol (switched on to remove now: test your apps to make sure they _don't_
do this, because as some point we should just yank it), fixup head/tail/fold.
Also tweak "make allyesconfig" so anything starting with CONFIG_DEBUG gets
left switched off. Possibly other things we want to put in the debug menu?
2006-01-30 01:30:39 +00:00
"Vladimir N. Oleynik"
8aa9e57149
support 64 arith. Close bug 136
2006-01-25 13:56:03 +00:00
Tim Riker
c1ef7bdd8d
just whitespace
2006-01-25 00:08:53 +00:00
Bernhard Reutner-Fischer
86f5c9906b
- add platform.h.
...
- use shorter boilerplate while at it.
2006-01-22 22:55:11 +00:00
Bernhard Reutner-Fischer
96002bba67
- cleanup Config.in. Use "select CONFIG_FOO" and add the corresponding
...
"depends on CONFIG_BAR" instead of the if !CONFIG_FOO ...default y stanza.
2006-01-19 14:42:23 +00:00
Bernhard Reutner-Fischer
37dec0e9e9
- make CONFIG_MD5SUM_SIZE_VS_SPEED configurable via menuconfig.
...
- use shorter boilerplate.
2006-01-17 12:07:03 +00:00
Bernhard Reutner-Fischer
7ca61b6f33
- shared libbusybox.
...
- IMA compilation option (aka IPO, IPA,..)
Please holler if i broke something..
2006-01-15 14:04:57 +00:00
Rob Landley
fb8c4983a6
Fix bug 603: "chown :root thingy" should work now.
2006-01-09 03:45:43 +00:00
Rob Landley
251161f75c
Bug 624 wants quoted char support for printf, so you can do something like:
...
printf '%d\n' '"x"'
and have it print out 120. This is the smallest implementation I can think
of at the moment.
2006-01-06 20:28:05 +00:00
Rob Landley
f8ec1b51f3
No, we _want_ the suid and sgid bits reverted by chown, for security reasons.
...
They mean something different when the user they're switching to is different,
so if you still want suid you reset it afterwards. This is a safety feature.
2006-01-06 18:22:05 +00:00
Bernhard Reutner-Fischer
9a14bd04f8
- Stephane Billiart writes:
...
Fix the compilation of head and tail.
thanks!
2005-12-15 11:47:16 +00:00
Rob Landley
164c5c80ba
Eliminate unnecessary allocation from md5sum that was leaked without ever being used.
2005-12-15 06:51:52 +00:00
Bernhard Reutner-Fischer
5816ccb190
- wrap label GET_COUNT in #if ENABLE_FEATURE_FANCY_applet to avoid warning
...
about unused label.
2005-12-13 10:48:45 +00:00
Rob Landley
a75c180e53
Bug 310: be consistent about stat/lstat and chown/lchown to avoid accidentally
...
modifying permissions or ownership when twiddling symlinks.
2005-12-12 06:58:53 +00:00
Rob Landley
cdbae77823
printf() arguments shouldn't be passed straight from user supplied data.
...
(Security thingy.)
2005-12-12 06:49:33 +00:00
Glenn L McGrath
0bd0257fe0
Add build options to control SuS compatability, allows numeric
...
option handling to be disabled.
Defaults to enabled, so no changes in default behaviour
2005-12-11 03:09:05 +00:00
Bernhard Reutner-Fischer
d77b781c1f
- remove unused variable have_read_stdin
...
- use FLAG_WIDTH
2005-12-10 20:13:54 +00:00
Paul Fox
377bdaff3b
avoid mixed declarations, to support older compilers just a little longer.
2005-12-08 18:48:20 +00:00
Rob Landley
746cfc8bf0
Another cleanup patch that's been in my tree for a while. Again I think it's
...
originally from Bernhard Fischer...
2005-12-02 17:55:45 +00:00
Rob Landley
2f30932eca
Fix cp /dev/null filename, and a few in-passing cleanups.
2005-11-01 21:55:14 +00:00
Bernhard Reutner-Fischer
47ea7b7f96
- Matthias Wenzel writes:
...
without the fix below md5sum will always report a correct md5 on _any_
wrongly formattet input files.
- use short boilerplate and remove superfluous keyword extern.
2005-10-27 14:43:27 +00:00
Bernhard Reutner-Fischer
ab1878245c
* uniq.c: remove unneeded include and use short boilerplate.
...
* coreutils.h: remove prototype of non-existing xgetoptfile_sort_uniq
and add boilerplate.
* networking/{ipaddr,ip,iplink,iproute,iptunnel}.c: touch includes
and use short boilerplate.
* libiproute/iproute.c: rename round to avoid clashes with older
SuSE gcc and use short boilerplate.
2005-10-26 10:47:26 +00:00
"Vladimir N. Oleynik"
1f0262bcdb
another more const
2005-10-20 11:17:48 +00:00
"Vladimir N. Oleynik"
a2eec6051f
RESERVE_CONFIG_BUFFER --> bb_common_bufsiz1
2005-10-15 13:45:32 +00:00
"Vladimir N. Oleynik"
6f347ef9dc
common BUFSIZ BSS buffer, small reduce code, data and bss
2005-10-15 10:23:55 +00:00
"Vladimir N. Oleynik"
f704b27b5b
- new bb_opt_complementally syntax, use [-:?] only - 'free' chars
...
- new bb_getopt_ulflags features: check max and min args, convert first argv to options special for ar and tar applets
- use bb_default_error_retval for env applet
2005-10-14 09:56:52 +00:00
"Vladimir N. Oleynik"
6c35c7c976
usage bb_dev_null
2005-10-12 15:34:25 +00:00
"Vladimir N. Oleynik"
3ade65fc04
remove 1 CR, correct strange bb_opt_complementally, add #if 0 and XXX-comment: pleace examine this\!
2005-10-12 14:36:42 +00:00
"Vladimir N. Oleynik"
064f04e7e2
- use complementally '!' to '?' - 'ask' is best 'free' char for this.
...
- more long opt compatibility, can set flag for long opt struct now
- more logic: check opt-depend requires and global requires, special for 'id' and 'start-stop-daemon' applets.
2005-10-11 14:38:01 +00:00
Rob Landley
ae907f38f0
When lstat returns an error (such as file not found), the value of
...
st_mode is random garbage (under uClibc), leading to random triggering
of the S_ISDIR() case when the destination will be a normal file which
doesn't exist yet. I.E. checking the return value of lstat is not optional.
2005-10-09 11:16:01 +00:00
Rob Landley
f1048143ee
Rob Sullivan added character and equivalence classes to tr. I changed some
...
comments.
2005-10-08 21:21:08 +00:00
Rob Landley
45ad0e87d6
Rename CONFIG_SORT_BIG to CONFIG_FEATURE_SORT_BIG so allbareconfig can find it.
2005-10-08 17:48:25 +00:00
"Vladimir N. Oleynik"
b31cb87fdc
to bb_getopt_ulflags()
2005-10-06 15:30:17 +00:00