summaryrefslogtreecommitdiff
path: root/shell/hush.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Larry Doolittle writes:Eric Andersen2004-04-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | This is a bulk spelling fix patch against busybox-1.00-pre10. If anyone gets a corrupted copy (and cares), let me know and I will make alternate arrangements. Erik - please apply. Authors - please check that I didn't corrupt any meaning. Package importers - see if any of these changes should be passed to the upstream authors. I glossed over lots of sloppy capitalizations, missing apostrophes, mixed American/British spellings, and German-style compound words. What is "pretect redefined for test" in cmdedit.c? Good luck on the 1.00 release! - Larry
* Wolfgang Denk writes:Eric Andersen2004-04-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | He, there is a bug in HUSH's handling of "if" / "elif" commands: $ if true > then > echo 1 > elif > true > then > echo 2 > elif > true > then > echo 3 > else > echo 4 > fi 1 2 3 $ The same bug exists in all versions of HUSH from BB v0.60.x up to and including v1.00-pre9. The attached patch fixes this: $ if true > then > echo 1 > elif > true > then > echo 2 > elif > true > then > echo 3 > else > echo 4 > fi 1 $ Best regards, Wolfgang Denk
* Jamie Guinan writes:Eric Andersen2004-04-121-2/+2
| | | | | | | | | | | 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
* Remove the CONFIG_FEATURE_SH_APPLETS_ALWAYS_WIN option. It was sortofEric Andersen2004-04-071-12/+0
| | | | stupid and didn't work properly anyways.
* s/fileno\(stdin\)/STDIN_FILENO/gEric Andersen2004-03-271-1/+1
| | | | s/fileno\(stdout\)/STDOUT_FILENO/g
* Remove trailing whitespace. Update copyright to include 2004.Eric Andersen2004-03-151-56/+56
|
* Update a bunch of docs. Run a script to update my email addr.Eric Andersen2003-07-141-8/+10
|
* Major coreutils update.Manuel Novoa III2003-03-191-33/+33
|
* Make hush comple once againEric Andersen2002-12-061-1/+1
|
* Change if(x)free(x); to free(x);Aaron Lehmann2002-11-281-3/+2
|
* Nice patch from Wolfgang Denk <wd@denx.de> to provide hush withEric Andersen2002-04-131-39/+308
| | | | shell loops (for, while, until) and control operators (||, &&)
* Fixup some silly prototype warningsEric Andersen2001-10-311-3/+3
|
* Add in some (theoretical) uClinux support. Some init cleanupsEric Andersen2001-10-281-1/+10
|
* Major rework of the directory structure and the entire build system.Eric Andersen2001-10-241-10/+11
| | | | -Erik
* Add an option to make the shells not advertise their busybox natureEric Andersen2001-10-191-1/+4
|
* Allow multiple shells to be enabled.Matt Kraai2001-08-011-4/+4
|
* Patch from vodz:Eric Andersen2001-07-121-5/+2
| | | | | | | Changed email address cmdedit API change optimizations for traceroute and md5sum added a new shared create_icmp_socket() function
* More thrashing about trying to make hush behave itself wrt jobEric Andersen2001-06-281-16/+18
| | | | control...
* Explicitly call setsid()Eric Andersen2001-06-261-0/+1
|
* Don't choke if /etc/profile is not availableEric Andersen2001-06-261-8/+7
|
* Vladimir's last_patch_15Glenn L McGrath2001-06-261-1/+1
|
* Fix the code for establishing a controlling terminal.Eric Andersen2001-06-251-28/+42
| | | | -Erik
* Some more cleanups. Of special importance, never free a pipeEric Andersen2001-06-221-27/+52
| | | | | | that still has running jobs. Instead, we ignore it and expect it to be cleaned by the background job stuff. -Erik
* Some cleanups for hush. Saves about 350bytes.Eric Andersen2001-06-221-98/+67
| | | | -Erik
* Another hush update from Larry:Eric Andersen2001-06-071-14/+16
| | | | | | | Fixes the interaction between if/then/else/fi syntax and variables. I planned to do it right from the beginning, but my implementation was buggy. Also adds the relevant test cases. Also adds some old Matt Kraai variable test cases that got left out somehow.
* A patch from Larry to fix pathological things like '>""'Eric Andersen2001-06-061-5/+13
|
* Don't close file descriptors when we are duplicating them.Matt Kraai2001-06-051-1/+2
|
* Cope gracefully when people type something, then hit ^C.Eric Andersen2001-05-311-1/+4
| | | | -Erik
* Plug another memory leakEric Andersen2001-05-241-0/+1
|
* Plug another memory leak in hush. This one showed up when backtickedEric Andersen2001-05-231-0/+1
| | | | | commands were run. This one was sure a bugger to find. -Erik
* Fix a massive memory leak in the run_list_test() function.Eric Andersen2001-05-231-33/+11
| | | | | | Rename run_list_test() as free_pipe_list(). Rename run_pipe_test() as free_pipe(). -Erik
* Commit a patch by Larry Doolittle which fixes recursive calls to file_peek,Matt Kraai2001-05-231-7/+8
| | | | and improves some debugging messages.
* Excellent. This patch from Larry fixes the behavior of hushEric Andersen2001-05-221-1/+3
| | | | when builtins are included in pipes.
* Fix this case. No, really this time.Eric Andersen2001-05-221-46/+61
| | | | | | | | | unset FOO export FOO=bar FOO=baz echo "global env: " `env | grep ^FOO` echo "local env: " `set | grep ^FOO` -Erik
* Fix a race. Sometimes by the time we got to checkjobs(), theEric Andersen2001-05-221-12/+27
| | | | | pipe struct had already been freed. Return immediately if the pipe is NULL.
* Oops. Remove some debug noise I left in.Eric Andersen2001-05-221-5/+1
|
* Updates from both Vladimir and LarryEric Andersen2001-05-221-64/+89
|
* Patch from Lars Kellogg-Stedman <lars@larsshack.org> to fix bugEric Andersen2001-05-211-3/+3
| | | | #1130 (i.e. When you turn on features it should always ADD features)
* The latest patch from LarryEric Andersen2001-05-211-31/+61
|
* This is a patch from Vladimir:Eric Andersen2001-05-191-198/+184
| | | | | | | | | | | | | | | | | | | | | | | | | > I rewrite *local_variable* function in hush.c with: > 1) remove many memory leaks > 2) add support read_only protect (require write builtin function for set this, > I write this special for variable HUSH_VERION=0.01) > 3) commad read set only local variable now > 4) remove many error messages if "set unset export" not defined variable > (bash syntax not put and set error code). Hmm, if I set result to -1, you hush > called waitpid and returned with error "no waitpid" ( i not found place this > error). > 5) destroy error in new version check xgetcwd()==NULL and set "(unknow)" - > this have error: crashe in next call `pwd`, but xgetcwd(not null) called > free(arg). > 6) next add integraion with libbb Valdimir's patch missed two cases of local variable handling FOO=bar export FOO=baz unset FOO and export FOO=bar FOO=baz which were working before, so I fixed those two cases.
* It turns out job control in both hush and lash was broken by theEric Andersen2001-05-171-10/+22
| | | | | | signal handling in cmdedit.c. Disabling it makes the shells behave themselves again. hush isn't quite there, but is getting close... -Erik
* Move init of a bunch of globals into main so we are at leastEric Andersen2001-05-161-7/+16
| | | | | a bit more reentrant. -Erik
* Fix the behavior of local shell variables to match that of bash and ash.Eric Andersen2001-05-151-25/+109
| | | | -Erik
* Oops. I left in some debug noise.Eric Andersen2001-05-151-1/+0
|
* Write set_local_var() and fixup lookup_param() so you can now useEric Andersen2001-05-151-4/+101
| | | | | shell local variables. -Erik
* This patch covers one big part of variable handling.Eric Andersen2001-05-151-5/+49
| | | | | | | | | | | | | | | $ a=b foo should be handled correctly. $ a=b is parsed OK, but the actual variable setting is not yet written. Except for some weird exceptions related to quoting rules, this code passes (matches ash behavior) all the tests I threw at it. If someone now writes set_local_var(), and updates lookup_param() to match, we can claim success! - Larry
* Fix up some silly warningsEric Andersen2001-05-111-3/+3
|
* Fix a segfault in lash, hush, and cmdedit. Each of these usedEric Andersen2001-05-111-0/+6
| | | | | | 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
* Use xgetcwdEric Andersen2001-05-111-2/+2
|
* A few more structural updates for job control.Eric Andersen2001-05-081-4/+13
| | | | -Erik