Commit Graph

164 Commits

Author SHA1 Message Date
Bernhard Reutner-Fischer
86f5c9906b - add platform.h.
- use shorter boilerplate while at it.
2006-01-22 22:55:11 +00:00
"Vladimir N. Oleynik"
264e771b8b Reduce exported from lash applet 2005-09-22 14:35:29 +00:00
Mike Frysinger
dcc40b7ecc Shaun Jackman writes: Newlib uses both __getopt_initialized and optind to track initialization of getopt() 2005-03-04 01:33:17 +00:00
Eric Andersen
acd647c877 Joe.C writes:
This bug is in busybox 1.0.0-rc2. When using lash exec
builtin with redirection, the opened file fd keep increasing.
For example, please try the following command with lash.


ls -al /proc/<lash pid>/fd
exec /bin/sh 2>/dev/null
ls -al /proc/<lash pid>/fd

  The last 'ls' command output will look like this. The fd
number 4 shouldn't exist.

lrwx------    1 501      100         64 Aug 13 13:56 4 -> /dev/pts/5
l-wx------    1 501      100         64 Aug 13 13:56 2 -> /dev/null
lrwx------    1 501      100         64 Aug 13 13:56 1 -> /dev/pts/5
lrwx------    1 501      100         64 Aug 13 13:56 0 -> /dev/pts/5
dr-xr-xr-x    3 501      100          0 Aug 13 13:56 ..
dr-x------    2 501      100          0 Aug 13 13:56 .

  This one-line patch fix this problem by setting CLOEXEC flag for
squirrel fd. Please apply.

Joe.C
2004-08-16 08:38:34 +00:00
Eric Andersen
e3efc9230c Jamie Guinan writes:
It looks like latest uClibc defines ARCH_HAS_MMU, but a few busybox files
test UCLIBC_HAS_MMU, resulting in vfork() getting called instead of
fork(), etc.

Patch below.   Only tested for lash.

Cheers,
-Jamie
2004-04-12 17:59:24 +00:00
Eric Andersen
075dd81c44 Remove the CONFIG_FEATURE_SH_APPLETS_ALWAYS_WIN option. It was sortof
stupid and didn't work properly anyways.
2004-04-07 09:34:27 +00:00
Eric Andersen
70060d25d2 s/fileno\(stdin\)/STDIN_FILENO/g
s/fileno\(stdout\)/STDOUT_FILENO/g
2004-03-27 10:02:48 +00:00
Eric Andersen
c7bda1ce65 Remove trailing whitespace. Update copyright to include 2004. 2004-03-15 08:29:22 +00:00
Eric Andersen
d20d37559f Fix some goofy formatting 2004-03-12 22:08:42 +00:00
Glenn L McGrath
c45146cf24 Patch by Felipe Kellermann to fix a compiler compatability problem 2004-03-05 12:55:30 +00:00
Eric Andersen
95b26250a7 oops. Leave the default feature set enbled for now... 2004-02-10 01:30:21 +00:00
Eric Andersen
37032b4d6c Initial effort at disabling job control as well 2004-02-10 01:28:36 +00:00
Eric Andersen
ff9ad47d79 Support disabling pipe and redirect support 2004-02-10 01:07:45 +00:00
Eric Andersen
cb81e6484d Update a bunch of docs. Run a script to update my email addr. 2003-07-14 21:21:08 +00:00
Manuel Novoa III
cad5364599 Major coreutils update. 2003-03-19 09:13:01 +00:00
Eric Andersen
ece8fc2b9b Squash a warning by making function declaration a proper prototype 2002-12-11 04:26:28 +00:00
Aaron Lehmann
a170e1c858 Change if(x)free(x); to free(x); 2002-11-28 11:27:31 +00:00
Eric Andersen
7ab93d9980 Teach lash to get $1 $2 $3 etc correct
-Erik
2002-11-08 09:40:02 +00:00
Eric Andersen
ad082987d0 Use %m, not strerror, and strerror(err) was broken anyways and should have been
strerror(errno).  Problem noted by Alexey V. Neyman <alex.neyman@auriga.ru>
2002-09-30 20:20:20 +00:00
Eric Andersen
6f2ebcaa01 Avoid calling exit() from within fork/vfork'ed processes.
-Erik
2002-09-26 13:59:40 +00:00
Eric Andersen
7373e485d3 A couple of small bugfixes from Marshall M. Midden <m4@brecis.com> 2002-07-31 04:04:47 +00:00
Eric Andersen
0d2d1eb599 Fix a buffer overflow found by Gerardo Puga <gpuga@gioia.ing.unlp.edu.ar>
-Erik
2002-06-06 13:33:01 +00:00
Matt Kraai
1f0c43668a Remove == TRUE' tests and convert != TRUE' and `== FALSE' tests to use !. 2001-12-20 23:13:26 +00:00
Eric Andersen
2423b12dae Begin moving things to busybox.net
-Erik
2001-12-08 01:56:15 +00:00
Matt Kraai
c8227639db Change strdup calls to xstrdup (patch from Steve Merrifield). 2001-11-12 16:57:27 +00:00
Eric Andersen
72f9a4277f Add in some (theoretical) uClinux support. Some init cleanups 2001-10-28 05:12:20 +00:00
Eric Andersen
bdfd0d78bc Major rework of the directory structure and the entire build system.
-Erik
2001-10-24 05:00:29 +00:00
Eric Andersen
d63dee4019 Add an option to make the shells not advertise their busybox nature 2001-10-19 00:22:23 +00:00
Eric Andersen
f0a4ac8216 Patch from Magnus Damm <damm@opensource.se> to avoid lash hanging
on serial ports
2001-10-03 11:23:42 +00:00
Eric Andersen
5d60a46269 Fix a warning and potential segfault in lash when BB_FEATURE_CLEAN_UP
is enabled
2001-08-22 05:32:24 +00:00
Matt Kraai
2d91deba45 Allow multiple shells to be enabled. 2001-08-01 17:21:35 +00:00
Eric Andersen
7467c8d3b6 Patch from vodz:
Changed email address
    cmdedit API change
    optimizations for traceroute and md5sum
    added a new shared create_icmp_socket() function
2001-07-12 20:26:32 +00:00
Eric Andersen
07abfe2092 don't whine if all we need to do is remove a bg job 2001-06-27 17:29:11 +00:00
Eric Andersen
4b6b5e4314 Re-enable globbing (I'd accidentaly removed it) and finish off the last
of the job control polishing.  Works fine now.
 -Erik
2001-06-27 04:30:11 +00:00
Eric Andersen
2d848a476a This should finish off the job control issues with lash. Make certain
we have a controlling terminal...
 -Erik
2001-06-25 17:11:54 +00:00
Eric Andersen
8a646dd293 This commit guts lash, restoring it to what it was originally intended to do,
just be a simple command line interpreter with basic pipe, redirect, and job
control.  For all the more fancy things, people should use hush or ash.
 -Erik
2001-06-21 16:38:11 +00:00
Eric Andersen
77d9268892 Patch from larry to fix some grammar errors. 2001-05-23 20:32:09 +00:00
Eric Andersen
004015e9c4 Patch from Lars Kellogg-Stedman <lars@larsshack.org> to fix bug
#1130 (i.e. When you turn on features it should always ADD features)
2001-05-21 20:30:51 +00:00
Matt Kraai
59df6f7398 Change 'printf("%s\n", ...)' into 'puts(...)'. Noted and patched in hostname.c
by Larry Doolittle.
2001-05-16 14:21:09 +00:00
Eric Andersen
cfa88ecb72 Fix up some silly warnings 2001-05-11 18:08:16 +00:00
Eric Andersen
5f265b755a Fix a segfault in lash, hush, and cmdedit. Each of these used
xgetcwd, but did not check the return for a NULL, and then continued
to call strlen on the NULL when the cwd had been removed from under it.
 -Erik
2001-05-11 16:58:46 +00:00
Mark Whitley
4b541a8817 Moved some #ifdefs down below #include "busybox.h" where they belong. 2001-04-25 17:10:30 +00:00
Eric Andersen
ed424dbf1d Some patches from Gennady Feldman. Fixed a glob problem such that
'ls *.h Config.h' works.  Fixed a silly typo with fg/bg process control.
Made cmdedit exit sanely when it cannot read input.
2001-04-23 15:28:28 +00:00
Matt Kraai
4ef40c02f4 Another banner consolidation from Larry Doolittle <ldoolitt@recycle.lbl.gov>. 2001-04-12 20:44:21 +00:00
Matt Kraai
be66ad3212 Fix handling of '' and "". 2001-04-12 15:42:17 +00:00
Eric Andersen
e5dfced23a Apply Vladimir's latest cleanup patch.
-Erik
2001-04-09 22:48:12 +00:00
Matt Kraai
2129f97cd9 Avoid segfault when export is invoked with no arguments. Thanks to
Gennady Feldman.
2001-04-04 17:50:04 +00:00
Eric Andersen
84e229cfbe Add in a new standalone env applet for fixing up app's environments
-Erik
2001-03-29 22:48:33 +00:00
Mark Whitley
a82a00397f Fix to last patch: locale code should be 9, not 7. 2001-03-27 17:07:15 +00:00
Mark Whitley
1c6581a865 Applied patch from Vladimir N. Oleynik to add locale support to the shell per
bug report from Ralph Jones.
2001-03-27 16:35:16 +00:00