people/mcb30/busybox.git
18 years agoFix it so usage is _always_ in sync with applets.c. Previously,
andersen [Tue, 6 Apr 2004 14:28:35 +0000 (14:28 +0000)]
Fix it so usage is _always_ in sync with applets.c.  Previously,
broken depends allowed these to get out of sync.

git-svn-id: svn://busybox.net/trunk/busybox@8702 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMichael Tokarev, mjt at tls dot msk dot ru writes:
andersen [Tue, 6 Apr 2004 12:06:03 +0000 (12:06 +0000)]
Michael Tokarev, mjt at tls dot msk dot ru writes:

Fix parsing of all tag-value pairs (in modules.conf in particular).
Without this fix, code chokes badly on lines where either value or
both tag+value are missing, like bare
 alias
line, or alias w/o the value like
 alias some-module
(syntactically incorrect, but no need for coredumps either).

git-svn-id: svn://busybox.net/trunk/busybox@8700 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMichael Tokarev, mjt at tls dot msk dot ru writes:
andersen [Tue, 6 Apr 2004 12:05:04 +0000 (12:05 +0000)]
Michael Tokarev, mjt at tls dot msk dot ru writes:

alias 'off' parsing fix.
It is not
 alias off module
it is
 alias module off

git-svn-id: svn://busybox.net/trunk/busybox@8699 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMichael Tokarev, mjt at tls dot msk dot ru writes:
andersen [Tue, 6 Apr 2004 12:04:14 +0000 (12:04 +0000)]
Michael Tokarev, mjt at tls dot msk dot ru writes:

Initialize all fields of struct dep_t.
Without that, e.g. `busybox modprobe -v char-major-10-144' *sometimes*
fails this way (strace):

 write(1, "insmod    nvram `\213\f\10\n", 21) = 21

Note the garbage after module name which is taken from the m_options field,
which is not initialized in the alias reading/parsing part.
(Shell properly complains to this command, telling it can't find the
closing backtick)

git-svn-id: svn://busybox.net/trunk/busybox@8698 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoChristian Grigis, christian.grigis at smartdata dot ch writes:
andersen [Tue, 6 Apr 2004 11:56:26 +0000 (11:56 +0000)]
Christian Grigis, christian.grigis at smartdata dot ch writes:

Hello everyone,

Busybox's insmod fails to locate a module when that module is the only one
existing in the /lib/modules directory (with a unique name).

Example:

# find /lib/modules/ -type f
/lib/modules/kernel/drivers/char/bios.o
# insmod bios
insmod: bios.o: no module by that name found
# touch /lib/modules/dummy
# find /lib/modules/ -type f
/lib/modules/kernel/drivers/char/bios.o
/lib/modules/dummy
# insmod bios
Using /lib/modules/kernel/drivers/char/bios.o

As long as there is another file in the /lib/modules directory, insmod
finds it OK.

I tracked the problem down to 'check_module_name_match()' in insmod.c:

It returns TRUE when a match is found, and FALSE otherwise. In the case
where there is only one module in the /lib/modules directory (or more that
one module, but all with the same name), 'recursive_action()' will return
TRUE and we end up on line 4196 in 'insmod.c' which returns an error.
[The reason it works with more than one module with different
names is that in this case there will always be one not matching,
'recursive_action()' will return FALSE and we end up in line 4189.]

Now, from the implementation of 'recursive_action()' and from other
usages of it (tar.c, etc.), it seems to me that FALSE should be returned
to indicate that we want to stop the recursion, so TRUE and FALSE should
be inverted in 'check_module_name_match()'.

At the same time, 'recursive_action()' continues to recurse even after
the recursive call has returned FALSE; again in my understanding and
other usages of it, we can safely stop recursing at this point.

Here is my patch against 1.00-pre8:

git-svn-id: svn://busybox.net/trunk/busybox@8697 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoYet more 'make allyesconfig' adjustments
andersen [Tue, 6 Apr 2004 11:51:45 +0000 (11:51 +0000)]
Yet more 'make allyesconfig' adjustments

git-svn-id: svn://busybox.net/trunk/busybox@8696 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMake 'allyesconfig' be a bit less stupid
andersen [Tue, 6 Apr 2004 11:46:56 +0000 (11:46 +0000)]
Make 'allyesconfig' be a bit less stupid

git-svn-id: svn://busybox.net/trunk/busybox@8695 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMinor tar test update
andersen [Tue, 6 Apr 2004 11:34:02 +0000 (11:34 +0000)]
Minor tar test update

git-svn-id: svn://busybox.net/trunk/busybox@8694 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoSimplify, make formatting better match the procps version
andersen [Tue, 6 Apr 2004 11:10:50 +0000 (11:10 +0000)]
Simplify, make formatting better match the procps version

git-svn-id: svn://busybox.net/trunk/busybox@8693 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoKill off the old 'tests' stuff. Write a ton of new tests for the
andersen [Tue, 6 Apr 2004 11:10:30 +0000 (11:10 +0000)]
Kill off the old 'tests' stuff.  Write a ton of new tests for the
'testsuite' dir.  Fix a bunch of broken tests.  Fix the testsuite
'runtest' script so it actually reports all failures and provides
meaningful feedback.
 -Erik

git-svn-id: svn://busybox.net/trunk/busybox@8692 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix non standard 'date -R' formatting
andersen [Tue, 6 Apr 2004 09:38:18 +0000 (09:38 +0000)]
Fix non standard 'date -R' formatting

git-svn-id: svn://busybox.net/trunk/busybox@8691 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix the test suite script so it actually works and actually flags
andersen [Tue, 6 Apr 2004 00:41:39 +0000 (00:41 +0000)]
Fix the test suite script so it actually works and actually flags
all errors as such.  Make verbose mode exit on FAIL and provide a
printout of the failed test run.

git-svn-id: svn://busybox.net/trunk/busybox@8690 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoSome test additions
andersen [Mon, 5 Apr 2004 18:46:24 +0000 (18:46 +0000)]
Some test additions

git-svn-id: svn://busybox.net/trunk/busybox@8689 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch adding support for ibs= and obs= to dd
andersen [Mon, 5 Apr 2004 14:30:15 +0000 (14:30 +0000)]
Patch adding support for ibs= and obs= to dd

git-svn-id: svn://busybox.net/trunk/busybox@8688 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPer suggestion by Pawel Sakowski, fix the dash_arith() prototype
andersen [Mon, 5 Apr 2004 13:24:07 +0000 (13:24 +0000)]
Per suggestion by Pawel Sakowski, fix the dash_arith() prototype
to return a long.  We were needlessly truncating to an int.

git-svn-id: svn://busybox.net/trunk/busybox@8687 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoTito, farmatito at tiscali dot it writes:
andersen [Mon, 5 Apr 2004 13:08:08 +0000 (13:08 +0000)]
Tito, farmatito at tiscali dot it writes:

Hi to all,
I discovered a little bug in hdparm.c
(really two little bugs...I've made...sigh! Mea culpa).
Some vars were  modified only locally and this could lead to wrong
results to be displayed with the -I switch and maybe with others.
Attached is a patch that fix it ( +88b).

Also attached is second patch that reduces the size a little bit:
   text    data     bss     dec     hex filename
    27984     624     900   29508    7344 hdparm.o (without bug-fix)
    28072     624     900   29596    739c hdparm.o (with bug-fix)
    28141     624     900   29665    73e1 hdparm.o (original)
but maybe this one can wait as we are in a feature freeze.

Ciao,
Tito

git-svn-id: svn://busybox.net/trunk/busybox@8686 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agorename uncompress.c to decompress_uncompress.c
andersen [Mon, 5 Apr 2004 13:03:34 +0000 (13:03 +0000)]
rename uncompress.c to decompress_uncompress.c
rename unzip.c to decompress_unzip.c

git-svn-id: svn://busybox.net/trunk/busybox@8685 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoEverything should be made as simple as possible. But no simpler.
andersen [Sat, 3 Apr 2004 12:36:03 +0000 (12:36 +0000)]
Everything should be made as simple as possible.  But no simpler.

git-svn-id: svn://busybox.net/trunk/busybox@8681 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoThe last patch broke:
landley [Thu, 1 Apr 2004 09:23:30 +0000 (09:23 +0000)]
The last patch broke:
sed -i "/^boo/a fred" ipsec.conf

Which works in gnu sed.  (And is _supposed_ to strip all the whitespace before
"fred".)

It also broke:
sed -i -e "/^boo/a \\" -e "   fred" ipsec.conf

I.E. there can legally be spaces between the a and the backslash at the end of
the line.

And strangely enough, gnu sed accepts the following syntax as well:
sed -i "/^boo/a \\  fred" ipsec.conf

Which is a way of having the significant whitespace at the start of the line,
all on one line.  (But notice that the whitespace BEFORE the slash is still
stripped, as is the slash itself.  And notice that the naieve placement of
"\n" there doesn't work, it puts an n at the start of the appended line.  The
double slashing is for shell escapes because you could escape the quote, you
see.  It's turned into a single backslash.  But \n there is _not_ turned into
a newline by the shell.  So there.)

This makes all three syntaxes work in my tests.  I should probably start
writing better documentation at some point.  I posted my current sedtests.py
file to the list, which needs a lot more tests added as well...

git-svn-id: svn://busybox.net/trunk/busybox@8680 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Hideki IWAMOTO adding support for 'cmp -n'
andersen [Wed, 31 Mar 2004 11:53:37 +0000 (11:53 +0000)]
Patch from Hideki IWAMOTO adding support for 'cmp -n'

git-svn-id: svn://busybox.net/trunk/busybox@8677 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoJunio Hamano, junio at twinsun dot com writes:
andersen [Wed, 31 Mar 2004 11:42:40 +0000 (11:42 +0000)]
Junio Hamano, junio at twinsun dot com writes:

The sed command in busybox 1.0.0-pre8 loses leading whitespace
in 'a' command ('i' and 'c' commands are also affected).  A
patch to fix this is attached at the end of this message.

The following is a transcript that reproduces the problem.  The
first run uses busybox 1.0.0-pre3 as "/bin/sed" command, which
gets the expected result.  Later in the test, /bin/sed symlink
is changed to point at busybox 1.0.0-pre8 and the test script is
run again, which shows the failure.

=== reproduction recipe ===
* Part 1.  Use busybox 1.0.0-pre3 as sed; this works.

root# cd /tmp
root# cat 1.sh
#!/bin/sh

cd /tmp
rm -f ipsec.conf ipsec.conf+
cat >ipsec.conf <<\EOF
version 2.0

config setup
        klipsdebug=none
        plutodebug=none
        plutostderrlog=/dev/null

conn %default
        keyingtries=1
        ...
EOF
sed -e '/^config setup/a\
nat_traversal=yes' ipsec.conf >ipsec.conf+
mv -f ipsec.conf+ ipsec.conf
root# sh -x 1.sh
+ cd /tmp
+ rm -f ipsec.conf ipsec.conf+
+ cat
+ sed -e /^config setup/a\
        nat_traversal=yes ipsec.conf
+ mv -f ipsec.conf+ ipsec.conf
root# cat ipsec.conf
version 2.0

config setup
        nat_traversal=yes
        klipsdebug=none
        plutodebug=none
        plutostderrlog=/dev/null

conn %default
        keyingtries=1
        ...
root# sed --version
sed: invalid option -- -
BusyBox v1.00-pre3 (2004.02.26-18:47+0000) multi-call binary

Usage: sed [-nef] pattern [files...]

* Part 2.  Continuing from the above, use busybox 1.0.0-pre8
  as sed; this fails.

root# ln -s busybox-pre8 /bin/sed-8
root# mv /bin/sed-8 /bin/sed
root# sed --version
This is not GNU sed version 4.0
root# sed --
BusyBox v1.00-pre8 (2004.03.30-02:44+0000) multi-call binary

Usage: sed [-nef] pattern [files...]
root# sh -x 1.sh
+ cd /tmp
+ rm -f ipsec.conf ipsec.conf+
+ cat
+ sed -e /^config setup/a\
        nat_traversal=yes ipsec.conf
+ mv -f ipsec.conf+ ipsec.conf
root# cat ipsec.conf
version 2.0

config setup
nat_traversal=yes
        klipsdebug=none
        plutodebug=none
        plutostderrlog=/dev/null

conn %default
        keyingtries=1
        ...
root#
=== reproduction recipe ends here ===

This problem was introduced in 1.0.0-pre4.  The problem is that
the command argument parsing code strips leading whitespaces too
aggressively.  When running the above example, the piece of code
in question gets "\n\tnat_traversal=yes" as its argument in
cmdstr variable (shown part in the following patch).  What it
needs to do at this point is to strip the first newline and
nothing else, but it instead strips all the leading whitespaces
at the beginning of the string, thus losing the tab character.
The following patch fixes this.

git-svn-id: svn://busybox.net/trunk/busybox@8676 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Thomas Winkler:
andersen [Wed, 31 Mar 2004 11:30:08 +0000 (11:30 +0000)]
Patch from Thomas Winkler:

ifconfig did not look up hostnames, so
ifconfig lo localhost
would not work, you have to do
ifconfig lo 127.0.0.1

git-svn-id: svn://busybox.net/trunk/busybox@8675 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Thomas Winkler showing the the system time for each process
andersen [Wed, 31 Mar 2004 11:21:24 +0000 (11:21 +0000)]
Patch from Thomas Winkler showing the the system time for each process
when running 'top'

git-svn-id: svn://busybox.net/trunk/busybox@8674 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Thomas Winkler -- vi -R did not work
andersen [Wed, 31 Mar 2004 11:12:51 +0000 (11:12 +0000)]
Patch from Thomas Winkler -- vi -R did not work

git-svn-id: svn://busybox.net/trunk/busybox@8673 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoSigh. what a mess.
andersen [Tue, 30 Mar 2004 09:33:18 +0000 (09:33 +0000)]
Sigh.  what a mess.

git-svn-id: svn://busybox.net/trunk/busybox@8672 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAs waldi noticed, checks for the size of an off_t and casting
andersen [Tue, 30 Mar 2004 09:21:54 +0000 (09:21 +0000)]
As waldi noticed, checks for the size of an off_t and casting
etc was also redundant and possibly buggy...

git-svn-id: svn://busybox.net/trunk/busybox@8671 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoGo ahead and kill off the FDISK_SUPPORT_LARGE_DISKS option,
andersen [Tue, 30 Mar 2004 09:13:05 +0000 (09:13 +0000)]
Go ahead and kill off the FDISK_SUPPORT_LARGE_DISKS option,
as it is redundant....

git-svn-id: svn://busybox.net/trunk/busybox@8670 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoThe fdisk llseek junk was redundant, since both uClibc and glibc
andersen [Tue, 30 Mar 2004 09:08:58 +0000 (09:08 +0000)]
The fdisk llseek junk was redundant, since both uClibc and glibc
automatically promote lseek and friends to their 64 bit counterparts
when CONFIG_LFS is enabled, since it enables __USE_FILE_OFFSET64

git-svn-id: svn://busybox.net/trunk/busybox@8669 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAs noted by Martin Schwenke, the example for find was wrong
andersen [Mon, 29 Mar 2004 08:20:08 +0000 (08:20 +0000)]
As noted by Martin Schwenke, the example for find was wrong

git-svn-id: svn://busybox.net/trunk/busybox@8667 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoYet more doc cleanups
andersen [Sat, 27 Mar 2004 11:35:46 +0000 (11:35 +0000)]
Yet more doc cleanups

git-svn-id: svn://busybox.net/trunk/busybox@8666 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAdd missing include files
andersen [Sat, 27 Mar 2004 11:26:32 +0000 (11:26 +0000)]
Add missing include files

git-svn-id: svn://busybox.net/trunk/busybox@8665 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agopasswd and sulogin also need libcrypt, via libbb/pw_encrypt()
andersen [Sat, 27 Mar 2004 10:08:53 +0000 (10:08 +0000)]
passwd and sulogin also need libcrypt, via libbb/pw_encrypt()

git-svn-id: svn://busybox.net/trunk/busybox@8664 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agos/fileno\(stdin\)/STDIN_FILENO/g
andersen [Sat, 27 Mar 2004 10:02:48 +0000 (10:02 +0000)]
s/fileno\(stdin\)/STDIN_FILENO/g
s/fileno\(stdout\)/STDOUT_FILENO/g

git-svn-id: svn://busybox.net/trunk/busybox@8663 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoVladimir N. Oleynik (vodz) writes:
andersen [Sat, 27 Mar 2004 09:49:57 +0000 (09:49 +0000)]
Vladimir N. Oleynik (vodz) writes:

Ok. Last patch reduce 73 bytes for compensate (and over) your changes ;-)

Comments:
Added cin_fileno variable, auto setted to 0 from BSS and have "eq" stdin
descriptor if isatty(stout)==0, removed global variable FILE* cin.
Removed default setting to terminal_width/terminal_height, this used
only from main() and setted after call get_terminal_width_height()
always correct.
Variable please_display_more_prompt changed to bits logic, have size
reducing.
--w
vodz

git-svn-id: svn://busybox.net/trunk/busybox@8662 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoUpdate docs
andersen [Sat, 27 Mar 2004 09:40:15 +0000 (09:40 +0000)]
Update docs

git-svn-id: svn://busybox.net/trunk/busybox@8661 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoBrian Pomerantz writes:
andersen [Tue, 23 Mar 2004 23:15:36 +0000 (23:15 +0000)]
Brian Pomerantz writes:

I've noticed a bug in the "autowidth" feature more, and is probably in
others.  The call to the function get_terminal_width_height() passes
in a file descriptor but that file descriptor is never used, instead
the ioctl() is called with 0.  In more_main() the call to
get_terminal_width_height() passes 0 as the file descriptor instead of
fileno(cin).  This isn't a problem when you more a file (e.g. "more
/etc/passwd") but when you pipe a file to it (e.g. "cat /etc/passwd |
more") the size of the terminal cannot be determined because file
descriptor 0 is not a terminal.  The fix is simple, I've attached a
patch for more.c and get_terminal_width_height.c.

BAPper

git-svn-id: svn://busybox.net/trunk/busybox@8656 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoSome corrections from vodz:
sandman [Mon, 22 Mar 2004 21:27:39 +0000 (21:27 +0000)]
Some corrections from vodz:
- Make -u/-l mutually exclusive
- Minor size reduction

git-svn-id: svn://busybox.net/trunk/busybox@8655 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoThe utc variable was not modified according to the -u/-l command line
sandman [Sun, 21 Mar 2004 18:01:46 +0000 (18:01 +0000)]
The utc variable was not modified according to the -u/-l command line
parameters.

git-svn-id: svn://busybox.net/trunk/busybox@8654 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoTito noticed a printf that should have been a bb_error_msg.
andersen [Sat, 20 Mar 2004 00:56:46 +0000 (00:56 +0000)]
Tito noticed a printf that should have been a bb_error_msg.

git-svn-id: svn://busybox.net/trunk/busybox@8652 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoOops.. got a bit to aggressive with size optimization and global replace. :-(
mjn3 [Fri, 19 Mar 2004 23:27:08 +0000 (23:27 +0000)]
Oops.. got a bit to aggressive with size optimization and global replace.  :-(

git-svn-id: svn://busybox.net/trunk/busybox@8651 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAs noted in a patch from Kendrick Hamilton, rmmod was only
andersen [Fri, 19 Mar 2004 21:00:03 +0000 (21:00 +0000)]
As noted in a patch from Kendrick Hamilton, rmmod was only
half way converted, and still used the old delete_module(),
call rather than a syscall, in one spot.

git-svn-id: svn://busybox.net/trunk/busybox@8650 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAdd missing ELFCLASSM for m68k
andersen [Fri, 19 Mar 2004 12:17:04 +0000 (12:17 +0000)]
Add missing ELFCLASSM for m68k

git-svn-id: svn://busybox.net/trunk/busybox@8647 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoOnly use R_68K_GOTOFF if it is defined
andersen [Fri, 19 Mar 2004 12:16:18 +0000 (12:16 +0000)]
Only use R_68K_GOTOFF if it is defined

git-svn-id: svn://busybox.net/trunk/busybox@8646 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix broken arg parsing (was not passing pointer to items so p, argc, and argv
andersen [Fri, 19 Mar 2004 10:53:52 +0000 (10:53 +0000)]
Fix broken arg parsing (was not passing pointer to items so p, argc, and argv
were only modified locally).  Fix error reporting to properly describe why
ioctls fail.

git-svn-id: svn://busybox.net/trunk/busybox@8644 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from vodz to fix the dynamic vars patch, which I should not
andersen [Tue, 16 Mar 2004 05:14:10 +0000 (05:14 +0000)]
Patch from vodz to fix the dynamic vars patch, which I should not
have checked in.  Vladimir writes:

Your patch have many problem.
1. You always added + time(). This cannot reset RANDOM=value for debuging
with
replay sequential.
2. Hmm. I examine bash 2.04 source. This pseudorandom generator use low bits
of
counter value. You use high bits. This make bad pseudorandom values after
have
0-value. For example, if + time() do remove, your generator always return 0
after
first generate 0.
3. Memory leak per call. Use ash-unlike unecessary bb_strdup function.
4. Unsupport show last $RANDOM value for "set" and "export" command.
5. Bloat code. Busybox-unlike patch - added unstandart feature as default
hardcode.

Last patch attached.

Erik, why you apply Paul patch with have 5-th point problem? :(

Last patch have ash change xwrite() to fresh libbb/bb_full_write interfase
(haved loop after EINTR).

--w
vodz

git-svn-id: svn://busybox.net/trunk/busybox@8632 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoOops. Using the wrong variable was a rather stupid
andersen [Mon, 15 Mar 2004 08:46:37 +0000 (08:46 +0000)]
Oops.  Using the wrong variable was a rather stupid
thing for me to do.

git-svn-id: svn://busybox.net/trunk/busybox@8631 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoRemove trailing whitespace. Update copyright to include 2004.
andersen [Mon, 15 Mar 2004 08:29:22 +0000 (08:29 +0000)]
Remove trailing whitespace.  Update copyright to include 2004.

git-svn-id: svn://busybox.net/trunk/busybox@8630 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoI redid route.
mjn3 [Sat, 13 Mar 2004 18:17:37 +0000 (18:17 +0000)]
I redid route.

git-svn-id: svn://busybox.net/trunk/busybox@8628 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoUpdate docs for start_stop_daemon to match reality. Update
andersen [Sat, 13 Mar 2004 08:33:10 +0000 (08:33 +0000)]
Update docs for start_stop_daemon to match reality.  Update
the reality a bit to better match debian behavior.

git-svn-id: svn://busybox.net/trunk/busybox@8627 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix some doc generation problems
andersen [Sat, 13 Mar 2004 08:32:14 +0000 (08:32 +0000)]
Fix some doc generation problems

git-svn-id: svn://busybox.net/trunk/busybox@8626 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoHideki IWAMOTO writes:
andersen [Fri, 12 Mar 2004 22:10:40 +0000 (22:10 +0000)]
Hideki IWAMOTO writes:

Current `tr' implementation has a problem, if `plain char' is signed.

[current cvs version]

>echo a | _install/usr/bin/tr '\0' '\377'
Segmentation fault (core dumped)

[patched version]

>echo a | _install/usr/bin/tr '\0' '\377'
a

git-svn-id: svn://busybox.net/trunk/busybox@8624 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix some goofy formatting
andersen [Fri, 12 Mar 2004 22:08:42 +0000 (22:08 +0000)]
Fix some goofy formatting

git-svn-id: svn://busybox.net/trunk/busybox@8623 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoAdd prototypes for safe_strtol and friends
andersen [Fri, 12 Mar 2004 22:08:13 +0000 (22:08 +0000)]
Add prototypes for safe_strtol and friends

git-svn-id: svn://busybox.net/trunk/busybox@8622 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix awk entry, which was not showing up in BusyBox.txt for some reason
andersen [Fri, 12 Mar 2004 22:07:10 +0000 (22:07 +0000)]
Fix awk entry, which was not showing up in BusyBox.txt for some reason

git-svn-id: svn://busybox.net/trunk/busybox@8621 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPaul Mundt, lethal at linux-sh dot org writes:
andersen [Thu, 11 Mar 2004 13:34:24 +0000 (13:34 +0000)]
Paul Mundt, lethal at linux-sh dot org writes:

Here's a follow-up replacement to the patch I sent earlier, this adjusts some
of the semantics of the dynamic variable setting. Namely, dynamic vars can hook
a set handler (which RANDOM uses to adjust the seed). They'll only lose their
dynamic status if they're unset.

I've used the same approach that bash does to come up with the random number,
mostly just for consistency.

For example:

$ echo $RANDOM
13759
$ echo $RANDOM
20057
$ echo $RANDOM
1502
$ export RANDOM=42
$ echo $RANDOM
24179
$ echo $RANDOM
2046
$ unset RANDOM
$ echo $RANDOM

$ export RANDOM=42
$ echo $RANDOM
42
$

git-svn-id: svn://busybox.net/trunk/busybox@8615 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Thomas Frohlich to fix an option ordering bug of mine.
bug1 [Wed, 10 Mar 2004 10:47:37 +0000 (10:47 +0000)]
Patch from Thomas Frohlich to fix an option ordering bug of mine.

git-svn-id: svn://busybox.net/trunk/busybox@8611 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoWhen displaying the size in 1kB blocks round up if an odd number of
bug1 [Wed, 10 Mar 2004 09:58:51 +0000 (09:58 +0000)]
When displaying the size in 1kB blocks round up if an odd number of
blocks

git-svn-id: svn://busybox.net/trunk/busybox@8610 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch by Seth W. Klein, the -l switch was reversed
bug1 [Wed, 10 Mar 2004 09:10:53 +0000 (09:10 +0000)]
Patch by Seth W. Klein, the -l switch was reversed

git-svn-id: svn://busybox.net/trunk/busybox@8609 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoIn spite of the feature freeze, check in a complete rework of route which
mjn3 [Wed, 10 Mar 2004 07:42:38 +0000 (07:42 +0000)]
In spite of the feature freeze, check in a complete rework of route which
fixes some bugs, adds some error checking, and removes _lots_ of bloat.
Text size on i386...
              old     new
   ipv6      5425    3523
   no ipv6   3143    2193

git-svn-id: svn://busybox.net/trunk/busybox@8607 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoNote that /proc must be mounted for filesystem type autodetection
andersen [Tue, 9 Mar 2004 21:32:57 +0000 (21:32 +0000)]
Note that /proc must be mounted for filesystem type autodetection
to work.  Without /proc mounted, one must explicitly specify the
type of every filesystem being mounted.

git-svn-id: svn://busybox.net/trunk/busybox@8604 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoDavid Anders (prpplague) submitted this patch to allow login to work
andersen [Tue, 9 Mar 2004 21:27:32 +0000 (21:27 +0000)]
David Anders (prpplague) submitted this patch to allow login to work
when the device nodes are symlinks on a read only file system.

git-svn-id: svn://busybox.net/trunk/busybox@8603 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix broken sort order flags.
mjn3 [Mon, 8 Mar 2004 10:54:29 +0000 (10:54 +0000)]
Fix broken sort order flags.

git-svn-id: svn://busybox.net/trunk/busybox@8601 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoMy bug. :-(
mjn3 [Mon, 8 Mar 2004 05:44:30 +0000 (05:44 +0000)]
My bug.  :-(

git-svn-id: svn://busybox.net/trunk/busybox@8600 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix/eliminate use of atol
andersen [Sat, 6 Mar 2004 22:11:45 +0000 (22:11 +0000)]
Fix/eliminate use of atol

git-svn-id: svn://busybox.net/trunk/busybox@8598 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Matt Kraai to fix debian bug number 231994.
bug1 [Sat, 6 Mar 2004 09:12:55 +0000 (09:12 +0000)]
Patch from Matt Kraai to fix debian bug number 231994.
There was an extra blank line preceding the first directory.

git-svn-id: svn://busybox.net/trunk/busybox@8595 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoWoops, how did that get in there
bug1 [Sat, 6 Mar 2004 07:38:27 +0000 (07:38 +0000)]
Woops, how did that get in there

git-svn-id: svn://busybox.net/trunk/busybox@8594 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoDon't build these support functions for uClibc, as it always supplies
mjn3 [Sat, 6 Mar 2004 00:32:54 +0000 (00:32 +0000)]
Don't build these support functions for uClibc, as it always supplies
versions.

git-svn-id: svn://busybox.net/trunk/busybox@8593 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from John Powers, adds multicast (rfc2090) and timeout (rfc2349)
bug1 [Fri, 5 Mar 2004 15:52:57 +0000 (15:52 +0000)]
Patch from John Powers, adds multicast (rfc2090) and timeout (rfc2349)
options

git-svn-id: svn://busybox.net/trunk/busybox@8582 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from duane no-name, optionally request additional items
bug1 [Fri, 5 Mar 2004 14:35:00 +0000 (14:35 +0000)]
Patch from duane no-name, optionally request additional items

git-svn-id: svn://busybox.net/trunk/busybox@8581 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch by Andrew Victor,
bug1 [Fri, 5 Mar 2004 14:25:49 +0000 (14:25 +0000)]
Patch by Andrew Victor,
In arpping.h, fix structure alignment of "struct arpMsg".
GCC can insert padding in the structure which causes udhcpd to send an
invalid ARP packet on the network.  It will then not receive a valid
reply, which can cause it to assign an IP address that's already in use
on the network.
(With kernels before 2.4.20, the "struct ethhdr" in linux/if_ether.h
wasn't marked as packed.  This is also an issue if your toolchain was
built with a pre-2.4.20 kernel).

git-svn-id: svn://busybox.net/trunk/busybox@8580 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix a typo, patch by Andrew Victor
bug1 [Fri, 5 Mar 2004 14:23:16 +0000 (14:23 +0000)]
Fix a typo, patch by Andrew Victor

git-svn-id: svn://busybox.net/trunk/busybox@8579 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Tony J. White to allow paths to be configured
bug1 [Fri, 5 Mar 2004 13:23:40 +0000 (13:23 +0000)]
Patch from Tony J. White to allow paths to be configured

git-svn-id: svn://busybox.net/trunk/busybox@8578 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch by Denis Vlasenko to add forground support.
bug1 [Fri, 5 Mar 2004 13:11:05 +0000 (13:11 +0000)]
Patch by Denis Vlasenko to add forground support.

git-svn-id: svn://busybox.net/trunk/busybox@8577 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix debugging output, patch by Hideki IWAMOTO
bug1 [Fri, 5 Mar 2004 13:04:39 +0000 (13:04 +0000)]
Fix debugging output, patch by Hideki IWAMOTO

git-svn-id: svn://busybox.net/trunk/busybox@8576 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch by Felipe Kellermann to fix a compiler compatability problem
bug1 [Fri, 5 Mar 2004 12:55:30 +0000 (12:55 +0000)]
Patch by Felipe Kellermann to fix a compiler compatability problem

git-svn-id: svn://busybox.net/trunk/busybox@8575 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Steven Scholz to fix compiler warnings
bug1 [Fri, 5 Mar 2004 09:38:16 +0000 (09:38 +0000)]
Patch from Steven Scholz to fix compiler warnings

git-svn-id: svn://busybox.net/trunk/busybox@8574 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoNew applet, eject, by Peter Willis
bug1 [Fri, 5 Mar 2004 07:26:28 +0000 (07:26 +0000)]
New applet, eject, by Peter Willis

git-svn-id: svn://busybox.net/trunk/busybox@8573 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoClose bracket in description from Peter Willis's eject applet
bug1 [Fri, 5 Mar 2004 06:47:25 +0000 (06:47 +0000)]
Close bracket in description from Peter Willis's eject applet

git-svn-id: svn://busybox.net/trunk/busybox@8572 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Vernon Sauder.
bug1 [Fri, 5 Mar 2004 05:47:19 +0000 (05:47 +0000)]
Patch from Vernon Sauder.
The off_t type is not a consistent size; it depends on the kernel options
(something about large file support). Therefore, the format string for
printing an address is not always the same.

git-svn-id: svn://busybox.net/trunk/busybox@8571 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix a compile error identiefied by Steven Scholz.
bug1 [Wed, 3 Mar 2004 21:12:16 +0000 (21:12 +0000)]
Fix a compile error identiefied by Steven Scholz.
Declare variables first for compatability.

git-svn-id: svn://busybox.net/trunk/busybox@8570 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoCheck file has execute permission for the current user, minor formating
bug1 [Mon, 1 Mar 2004 08:32:49 +0000 (08:32 +0000)]
Check file has execute permission for the current user, minor formating

git-svn-id: svn://busybox.net/trunk/busybox@8569 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoQuick fix for tftp truncation bug
bug1 [Thu, 26 Feb 2004 07:47:20 +0000 (07:47 +0000)]
Quick fix for tftp truncation bug

git-svn-id: svn://busybox.net/trunk/busybox@8558 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Denis Dowling to fix a ocuple of usage entries
bug1 [Wed, 25 Feb 2004 10:35:55 +0000 (10:35 +0000)]
Patch from Denis Dowling to fix a ocuple of usage entries

git-svn-id: svn://busybox.net/trunk/busybox@8557 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix option handling, -i or -t must be given, if both ignore the -t.
bug1 [Wed, 25 Feb 2004 09:30:06 +0000 (09:30 +0000)]
Fix option handling, -i or -t must be given, if both ignore the -t.
Use bb_getopt_ulflags.

git-svn-id: svn://busybox.net/trunk/busybox@8556 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoJoe.C, joe at numa dot com dot tw writes:
andersen [Tue, 24 Feb 2004 07:28:38 +0000 (07:28 +0000)]
Joe.C, joe at numa dot com dot tw writes:

Hi,

When downloading files over slow network (e.g. wireless/
internet) using IE, sometimes it will stop downloading and
show error message 'connection closed' when the download
is almost complete. This is because IE can't handle server
close connection properly.

Apache http_main.c fix this problem by close the connection
after client close the connection. This patch do exactly the
same thing. Please consider include this patch.

Joe.C

git-svn-id: svn://busybox.net/trunk/busybox@8555 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPrepare for release
andersen [Mon, 23 Feb 2004 09:14:07 +0000 (09:14 +0000)]
Prepare for release

git-svn-id: svn://busybox.net/trunk/busybox@8553 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agobb_full_fd_action was incorrectly returning an error message causing
bug1 [Mon, 23 Feb 2004 08:11:07 +0000 (08:11 +0000)]
bb_full_fd_action was incorrectly returning an error message causing
major breaking.

git-svn-id: svn://busybox.net/trunk/busybox@8552 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoBump up version in preparation for -pre8
andersen [Sun, 22 Feb 2004 12:27:04 +0000 (12:27 +0000)]
Bump up version in preparation for -pre8

git-svn-id: svn://busybox.net/trunk/busybox@8551 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFernando Silveira writes:
andersen [Sun, 22 Feb 2004 12:25:47 +0000 (12:25 +0000)]
Fernando Silveira writes:

Hi,

  Well, I made this patch a long time ago (08/2002) because it was a
  need of a project, but had no time to send it to you. It adds support
  to `autologin' option of the telnet protocol. It has been used since
  made with busybox 0.60.3 at production and I had no problems with it.
  I have ported it to the HEAD revision of the CVS server (20040211) and
  I hope you enjoy and apply it to the official sources. :)

Thanks a lot!

git-svn-id: svn://busybox.net/trunk/busybox@8550 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFix from Paul Kortekaas for syslog -C option, size should be in kB.
bug1 [Sun, 22 Feb 2004 12:17:33 +0000 (12:17 +0000)]
Fix from Paul Kortekaas for syslog -C option, size should be in kB.

git-svn-id: svn://busybox.net/trunk/busybox@8549 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Dmitry Zakharov, this line was missedfrom the last patch
bug1 [Sun, 22 Feb 2004 11:55:09 +0000 (11:55 +0000)]
Patch from Dmitry Zakharov, this line was missedfrom the last patch

git-svn-id: svn://busybox.net/trunk/busybox@8548 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoFor the time being, revert the changes for detecting copying
andersen [Sun, 22 Feb 2004 11:46:49 +0000 (11:46 +0000)]
For the time being, revert the changes for detecting copying
a directory into itself.  It is harder to do this correctly
than it appears.  Not trying at all seems a better compromise
for the time being, untill we can implement this correctly.

git-svn-id: svn://busybox.net/trunk/busybox@8547 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Chris Larson (kergoth), to allow multiple directores to be
bug1 [Sun, 22 Feb 2004 11:35:13 +0000 (11:35 +0000)]
Patch from Chris Larson (kergoth), to allow multiple directores to be
unmounted at once.

git-svn-id: svn://busybox.net/trunk/busybox@8546 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Vodz, cleanup memory usage, send strdup error messages to
bug1 [Sun, 22 Feb 2004 11:25:13 +0000 (11:25 +0000)]
Patch from Vodz, cleanup memory usage, send strdup error messages to
syslog.

git-svn-id: svn://busybox.net/trunk/busybox@8545 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoVodz. last_patch_128
bug1 [Sun, 22 Feb 2004 11:13:28 +0000 (11:13 +0000)]
Vodz. last_patch_128
- declare applet_using as static from applets.c
- small correction to cmdedit,
   previous version cleared history after Ctrl-C
- small spelling correction (by Friedrich Lobenstock)

git-svn-id: svn://busybox.net/trunk/busybox@8544 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from James Zhu, telnetd window resizing support.
bug1 [Sun, 22 Feb 2004 09:45:57 +0000 (09:45 +0000)]
Patch from James Zhu, telnetd window resizing support.

git-svn-id: svn://busybox.net/trunk/busybox@8543 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoUse bb_getopt_ulflags, marginal saving, better argument checking.
bug1 [Sun, 22 Feb 2004 09:11:33 +0000 (09:11 +0000)]
Use bb_getopt_ulflags, marginal saving, better argument checking.

git-svn-id: svn://busybox.net/trunk/busybox@8542 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoUse /var/lib/hwclock for adjtime, its really a state file rather than a
bug1 [Sun, 22 Feb 2004 08:33:37 +0000 (08:33 +0000)]
Use /var/lib/hwclock for adjtime, its really a state file rather than a
config file, so it should be in /etc, FHS mentions it also.

git-svn-id: svn://busybox.net/trunk/busybox@8541 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Florian Schirmer. compile fix for debug builds
bug1 [Sun, 22 Feb 2004 07:38:36 +0000 (07:38 +0000)]
Patch from Florian Schirmer. compile fix for debug builds

git-svn-id: svn://busybox.net/trunk/busybox@8540 69ca8d6d-28ef-0310-b511-8ec308f3f277

18 years agoPatch from Hideki IWAMOTO, output debugging messages to stderr
bug1 [Sun, 22 Feb 2004 07:20:25 +0000 (07:20 +0000)]
Patch from Hideki IWAMOTO, output debugging messages to stderr

git-svn-id: svn://busybox.net/trunk/busybox@8539 69ca8d6d-28ef-0310-b511-8ec308f3f277