commit bash-20121102 snapshot

This commit is contained in:
Chet Ramey
2012-12-07 11:05:26 -05:00
parent 65ae7211a9
commit f37a40a432
26 changed files with 28654 additions and 251 deletions
+14 -1
View File
@@ -233,8 +233,21 @@ parse_and_execute (string, from_file, flags)
should_jump_to_top_level = 0;
switch (code)
{
case FORCE_EOF:
case ERREXIT:
/* variable_context -> 0 is what eval.c:reader_loop() does in
these circumstances. Don't bother with cleanup here because
we don't want to run the function execution cleanup stuff
that will cause pop_context and other functions to run.
XXX - change that if we want the function context to be
unwound. */
if (exit_immediately_on_error && variable_context)
{
discard_unwind_frame ("pe_dispose");
variable_context = 0; /* not in a function */
}
should_jump_to_top_level = 1;
goto out;
case FORCE_EOF:
case EXITPROG:
if (command)
run_unwind_frame ("pe_dispose");