aboutsummaryrefslogtreecommitdiff
path: root/shell/ash.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Patch by Junio C Hamano to workaround a gcc compiler bug.bug12003-09-171-22/+23
| | | | | | | | | | | | | | | | | | | | | | The construct certain vintages of GCC (the one I have trouble with is 3.2.3) have trouble with looks like the following: static struct st a; static struct st *p = &a; struct st { int foo; }; static void init(void) { a.foo = 0; } The problem disappears if we move the struct declaration up to let the compiler know the shape of the struct before the first definition uses it, like this: struct st { int foo; }; /* this has been moved up */ static struct st a; static struct st *p = &a; static void init(void) { a.foo = 0; } git-svn-id: svn://busybox.net/trunk/busybox@7537 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from Bastian Blank to fix a problem when runing find under ash.bug12003-09-151-3/+3
| | | | | | | | | | | | | "If the shell is compiled with -DJOBS, this is all fine -- find wasn't stopped (it was killed), so it correctly uses WTERMSIG instead of WSTOPSIG. However, if the shell _isn't_ compiled with -DJOBS (which it isn't in d-i), only WSTOPSIG is used, which extracts the high byte instead of the low byte from the status code. Since the status code is 13 (SIGPIPE), "st" suddenly gets the value 0, which is equivalent to SIGEXIT. Thus, ash prints out "EXIT" on find's exit." git-svn-id: svn://busybox.net/trunk/busybox@7531 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch by Jean Wolter to fix a bug where a script wouldnt be executedbug12003-09-151-1/+4
| | | | | | | | | | | | | | | unless it had #!/bin/sh in the first line "It correctly locates the script, tries to execute it via execve which fails. After that it tries to hand it over to /bin/sh which fails too, since ash - neither provides the absolute pathname to /bin/sh - nor tries to lookup the script via PATH if called as "sh script" " git-svn-id: svn://busybox.net/trunk/busybox@7528 69ca8d6d-28ef-0310-b511-8ec308f3f277
* move all "-/bin/sh" "/bin/sh" and "sh" to libbb/messages.c file as onebug12003-09-021-1/+1
| | | | | | | | constant. Vodz last_patch_107 git-svn-id: svn://busybox.net/trunk/busybox@7365 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fix compile error and reducing size for libbb/get_console.c to previous size.bug12003-09-011-2/+2
| | | | | | | Vodz last_patch106 git-svn-id: svn://busybox.net/trunk/busybox@7345 69ca8d6d-28ef-0310-b511-8ec308f3f277
* vodz, last patch 103bug12003-08-291-64/+45
| | | | git-svn-id: svn://busybox.net/trunk/busybox@7278 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Rewrite timescmd() function to avoid the use of floating point and tomjn32003-08-131-16/+24
| | | | | | | | correct a bug in the seconds display where something like 65 seconds would be output as "1m65.000000s". git-svn-id: svn://busybox.net/trunk/busybox@7204 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Latest dash update from vodzandersen2003-08-061-152/+909
| | | | git-svn-id: svn://busybox.net/trunk/busybox@7177 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fixup typo noticed by Nick Fedchikandersen2003-07-291-1/+1
| | | | git-svn-id: svn://busybox.net/trunk/busybox@7131 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Vladimir N. Oleynik writes:andersen2003-07-291-26/+94
| | | | | | | | | | | Last patch have synced form Manuel Nova III xxreadtoken() function, corrected (C) form dash debian/copyright, removed my small mistake with IFS_BROKEN (thanks by Herbert), and synced cmdedit.c from current CVS (removed libc5 support, your email correction, my (C) year corertion). git-svn-id: svn://busybox.net/trunk/busybox@7129 69ca8d6d-28ef-0310-b511-8ec308f3f277
* This is synced from dash-0.4.17 and full ready for insert to new busyboxandersen2003-07-281-6700/+7085
| | | | | | | | | | | | | | version: ftp://ftp.simtreas.ru/pub/my/bb/new News: - code is smalest! - support ${var...} expr - used new very strongly steal controlling terminal git-svn-id: svn://busybox.net/trunk/busybox@7124 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Update a bunch of docs. Run a script to update my email addr.andersen2003-07-141-1/+1
| | | | git-svn-id: svn://busybox.net/trunk/busybox@7061 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Major coreutils update.mjn32003-03-191-16/+16
| | | | git-svn-id: svn://busybox.net/trunk/busybox@6751 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Only call free if it is necessaryandersen2003-01-141-1/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@6325 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Minor cleanup, identified by Stewart Brodie, patch by Vladimir N.bug12003-01-061-7/+4
| | | | | | | Oleynik git-svn-id: svn://busybox.net/trunk/busybox@6275 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fix STANDALONE_SHELL and ALWAYS_WIN options, last_path_73 by Vladimir N. Oleynikbug12002-12-231-9/+23
| | | | git-svn-id: svn://busybox.net/trunk/busybox@6241 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Small bugfix, last_patch72 from Vladimir N. Oleynikbug12002-12-111-1/+1
| | | | git-svn-id: svn://busybox.net/trunk/busybox@6172 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Command line history changes, lastpatch_71 from Vladimir N. Oleynikbug12002-12-091-8/+40
| | | | git-svn-id: svn://busybox.net/trunk/busybox@6140 69ca8d6d-28ef-0310-b511-8ec308f3f277
* - the number of commands in the history list is now configureable via thesandman2002-12-031-0/+9
| | | | | | | | | | config system - added a new config option to allow persistant history lists. This is currently only used by ash, but the calls ({load,save}_history) could be added to the other shells as well. git-svn-id: svn://busybox.net/trunk/busybox@6089 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fix warningandersen2002-10-221-0/+1
| | | | git-svn-id: svn://busybox.net/trunk/busybox@5695 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Apply last_patch51_3 from vodzandersen2002-10-221-1/+15
| | | | git-svn-id: svn://busybox.net/trunk/busybox@5684 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Don't even try to run ash on uClinux. It won't work.andersen2002-09-301-4/+4
| | | | | | | -Erik git-svn-id: svn://busybox.net/trunk/busybox@5608 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from "Joe.C" <joe@numa.com.tw>andersen2002-09-171-1/+14
| | | | git-svn-id: svn://busybox.net/trunk/busybox@5536 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Apply vodz last_path_51-2bug12002-08-231-395/+171
| | | | git-svn-id: svn://busybox.net/trunk/busybox@5361 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Run through indent, fix commentsbug12002-08-221-2790/+2705
| | | | git-svn-id: svn://busybox.net/trunk/busybox@5342 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Remove ckfree, and replace all references with free. Remove freefunc,aaronl2002-08-021-59/+41
| | | | | | | | which is also equivilent to free. Remove some if(x)free(x) redundancies. git-svn-id: svn://busybox.net/trunk/busybox@5146 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fixup warnings and undefined operations that show up in gcc-3.1andersen2002-07-111-2/+2
| | | | | | | -Erik git-svn-id: svn://busybox.net/trunk/busybox@5042 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from Stewart Brodie <stewart.brodie@pace.co.uk> to fix ash:andersen2002-07-041-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When alias support is not configured, ash believes that command parameters that look like dd's "if=/dev/zero" are requests to set a temporary environment variable whilst dd is running, even though it appears after the command name. This is caused by the re-use of the checkalias global variable to indicate when both alias checking and environment variable checking. The failure to reset this flag is due to the reset action being performed only inside the feature check CHECK_ASH_ALIAS. Hence ash works as expected when aliases are configured in, and fails when not. Example script using 'date' with different settings of TZ: # TZ=Europe/London # export TZ # date Thu May 30 17:18:49 BST 2002 # TZ=America/New_York date Thu May 30 12:19:10 EDT 2002 # date Thu May 30 17:19:12 BST 2002 # date TZ=America/New_York Thu May 30 12:19:30 EDT 2002 <----- wrong, should be BST time (or error!) # date Thu May 30 17:19:35 BST 2002 Attached is a patch against revision 1.52 of ash.c which moves the checks so that checkalias is updated regardless of whether CONFIG_ASH_ALIAS is set. With this patch applied, the command shown above which should generate an error does generate an error. I have tested this patch with the 'dd' command too and that now works correctly. git-svn-id: svn://busybox.net/trunk/busybox@5013 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Scrub pwd.h and grp.h handling so we don't have to play anyandersen2002-07-031-2/+2
| | | | | | | | silly games. -Erik git-svn-id: svn://busybox.net/trunk/busybox@5011 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from vodz to only setenv PATH when PATH changes, which is muchandersen2002-06-061-3/+3
| | | | | | | smarter than my quick fix. git-svn-id: svn://busybox.net/trunk/busybox@4863 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Fix for broken handling off BusyBox's own pwd/grp implementationssandman2002-06-041-2/+2
| | | | | | | [Parts of this patch may overlap with my other two patches] git-svn-id: svn://busybox.net/trunk/busybox@4856 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Add --login support. This is the bash way of starting a shell that shouldsandman2002-05-141-3/+10
| | | | | | | parse the profile files. git-svn-id: svn://busybox.net/trunk/busybox@4773 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Ensure that getenv("PATH") stays current, since otherwise cmdeditandersen2002-04-261-1/+3
| | | | | | | | | (which calls getenv("PATH")) would not operate upon the current PATH settings, which was really quite iritating. -Erik git-svn-id: svn://busybox.net/trunk/busybox@4677 69ca8d6d-28ef-0310-b511-8ec308f3f277
* vodz noted this line (as imported from Debian) is wrong, and has sinceandersen2002-04-241-2/+2
| | | | | | | been fixed upstream. git-svn-id: svn://busybox.net/trunk/busybox@4653 69ca8d6d-28ef-0310-b511-8ec308f3f277
* make ash prompt the same as other shells if cmdedit and fancyprompttimr2002-04-131-4/+7
| | | | git-svn-id: svn://busybox.net/trunk/busybox@4596 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Make private ash config options be publicandersen2002-01-091-125/+85
| | | | git-svn-id: svn://busybox.net/trunk/busybox@4050 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: errname-diffaaronl2001-12-311-2/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3972 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: initvar-diffaaronl2001-12-311-2/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3971 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: forkshell-diffaaronl2001-12-311-11/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3970 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: fgcmd-diffaaronl2001-12-311-3/+1
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3969 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: breakcmd-diffaaronl2001-12-311-1/+3
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3968 69ca8d6d-28ef-0310-b511-8ec308f3f277
* ash patch: addfname-diffaaronl2001-12-311-4/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3967 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from vodz to fix broken function prototypeandersen2001-12-211-2/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3936 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Remove `== TRUE' tests and convert `!= TRUE' and `== FALSE' tests to use !.kraai2001-12-201-2/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3925 69ca8d6d-28ef-0310-b511-8ec308f3f277
* The ash ansification diff!aaronl2001-12-061-356/+191
| | | | | | | Please tell me if you notice any problems resulting from this. git-svn-id: svn://busybox.net/trunk/busybox@3834 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Change strdup calls to xstrdup (patch from Steve Merrifield).kraai2001-11-121-3/+3
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3666 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Use fopen wrapper.kraai2001-11-121-4/+2
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3663 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from Aaron Lehmann <aaronl@vitelus.com>;andersen2001-10-311-26/+24
| | | | | | | | | | | | | | This diff does 2 things: 1) removes an unnecessary function. saves 64 bytes on i386 2) allows you to disable checking of mail (actually, it's now disabled by default). this would be a nice CML1 option, but for now it's a #(define|undef) in the C file like the other internal ash options. this saves an additional 352 bytes if you leave mail disabled. git-svn-id: svn://busybox.net/trunk/busybox@3617 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Patch from ASA <llb@udm.net.ru> to that source filesandersen2001-10-311-6/+25
| | | | | | | are properly passed their arguments. git-svn-id: svn://busybox.net/trunk/busybox@3613 69ca8d6d-28ef-0310-b511-8ec308f3f277
* Add in some (theoretical) uClinux support. Some init cleanupsandersen2001-10-281-1/+5
| | | | git-svn-id: svn://busybox.net/trunk/busybox@3596 69ca8d6d-28ef-0310-b511-8ec308f3f277