Age | Commit message (Collapse) | Author |
|
-Erik
|
|
we have a controlling terminal...
-Erik
|
|
that still has running jobs. Instead, we ignore it and expect
it to be cleaned by the background job stuff.
-Erik
|
|
-Erik
|
|
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
|
|
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.
|
|
|
|
|
|
-Erik
|
|
them in the presence of a quoting. Also revert my signal handling patch,
which seems to not solve the problem I thought it solved.
|
|
|
|
commands were run. This one was sure a bugger to find.
-Erik
|
|
Rename run_list_test() as free_pipe_list().
Rename run_pipe_test() as free_pipe().
-Erik
|
|
|
|
and improves some debugging messages.
|
|
when builtins are included in pipes.
|
|
unset FOO
export FOO=bar
FOO=baz
echo "global env: " `env | grep ^FOO`
echo "local env: " `set | grep ^FOO`
-Erik
|
|
pipe struct had already been freed. Return immediately if the
pipe is NULL.
|
|
|
|
|
|
#1130 (i.e. When you turn on features it should always ADD features)
|
|
|
|
> 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.
|
|
signal handling in cmdedit.c. Disabling it makes the shells behave
themselves again. hush isn't quite there, but is getting close...
-Erik
|
|
by Larry Doolittle.
|
|
a bit more reentrant.
-Erik
|
|
-Erik
|
|
|
|
shell local variables.
-Erik
|
|
$ 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
|
|
|
|
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
|
|
|
|
-Erik
|
|
-Erik
|
|
This way leaks memory, but oh well. We will probably fix that when we get
around to doing local variables.
|
|
Update some comments. Generate partial placeholders for the missing
builtins. Write builtin_umask. Properly treat exec without arguments
as a means to open/close files within the running script. Implement
"4<&-" that encodes for file descriptor closure.
|
|
trying to make job control work. This fix makes it so that
hush doesn't error out when init hasn't set up job control,
as in when init=/bin/sh
|
|
if true; then if true; then true; fi; fi
|
|
exec the real thing.
-Erik
|
|
|
|
stuff. Good luck getting things back into the foreground though...
-Erik
|
|
|
|
<ldoolitt@recycle.lbl.gov>. I'm just a patch whore. :)
|
|
in place, but something is still missing/wrong in there. Testing with
'grep foo &' seems to put _hush_ into the background. Pondering...
-Erik
|
|
Fixes bizarre suspension when executing `echo`.
|
|
|
|
Makes hush return code equal to that of the last command executed.
Fixes the mode where input comes from a file.
|
|
Minor improvements. Something is still broken with running
scripts via "hush filename". All the following are now handled
acceptably (matches ash, not bash).
if true; then echo foo1; fi
if
true; then echo foo2; fi
if true; false; then echo bar; else echo foo3; fi
if true || false; then echo foo4; fi
- Larry
|
|
|