/* Undo redirections before running exit trap on the way out of
set -e. Report by Mark Farrell 5/19/2014 */
if (exit_immediately_on_error && signal_is_trapped (0) &&
unwind_protect_tag_on_stack ("saved-redirects"))
run_unwind_frame ("saved-redirects");
/* Undo redirections before running exit trap on the way out of
set -e. Report by Mark Farrell 5/19/2014 */
if (exit_immediately_on_error && signal_is_trapped (0) &&
unwind_protect_tag_on_stack ("saved-redirects"))
run_unwind_frame ("saved-redirects");
int asynchronous, pipe_in, pipe_out;
struct fd_bitmap *fds_to_close;
{
int asynchronous, pipe_in, pipe_out;
struct fd_bitmap *fds_to_close;
{
- int rv, posix_time, old_flags, nullcmd;
+ int rv, posix_time, old_flags, nullcmd, code;
#if defined (HAVE_GETRUSAGE) && defined (HAVE_GETTIMEOFDAY)
struct timeval real, user, sys;
#if defined (HAVE_GETRUSAGE) && defined (HAVE_GETTIMEOFDAY)
struct timeval real, user, sys;
- rv = execute_command_internal (command, asynchronous, pipe_in, pipe_out, fds_to_close);
+ code = setjmp_nosigs (top_level);
+ if (code == NOT_JUMPED)
+ rv = execute_command_internal (command, asynchronous, pipe_in, pipe_out, fds_to_close);
if (time_format && *time_format)
print_formatted_time (stderr, time_format, rs, rsf, us, usf, ss, ssf, cpu);
if (time_format && *time_format)
print_formatted_time (stderr, time_format, rs, rsf, us, usf, ss, ssf, cpu);
second = command->value.Connection->second;
if (ignore_return && second)
second->flags |= CMD_IGNORE_RETURN;
second = command->value.Connection->second;
if (ignore_return && second)
second->flags |= CMD_IGNORE_RETURN;
/* If we are re-running this as the result of executing the `command'
builtin, do not expand the command words a second time. */
if ((simple_command->flags & CMD_INHIBIT_EXPANSION) == 0)
/* If we are re-running this as the result of executing the `command'
builtin, do not expand the command words a second time. */
if ((simple_command->flags & CMD_INHIBIT_EXPANSION) == 0)
execute_subshell_builtin_or_function
(words, simple_command->redirects, builtin, func,
pipe_in, pipe_out, async, fds_to_close,
execute_subshell_builtin_or_function
(words, simple_command->redirects, builtin, func,
pipe_in, pipe_out, async, fds_to_close,
{
error_trap = savestring (error_trap);
add_unwind_protect (xfree, error_trap);
{
error_trap = savestring (error_trap);
add_unwind_protect (xfree, error_trap);
{
return_trap = savestring (return_trap);
add_unwind_protect (xfree, return_trap);
{
return_trap = savestring (return_trap);
add_unwind_protect (xfree, return_trap);