+ save_parser_state (&pstate);
+ save_subst_varlist = subst_assign_varlist;
+ subst_assign_varlist = 0;
+
+#if defined (JOB_CONTROL)
+ if (sig != DEBUG_TRAP) /* run_debug_trap does this */
+ save_pipeline (1); /* XXX only provides one save level */
+#endif
+
+ /* If we're in a function, make sure return longjmps come here, too. */
+ save_return_catch_flag = return_catch_flag;
+ if (return_catch_flag)
+ {
+ COPY_PROCENV (return_catch, save_return_catch);
+ function_code = setjmp_nosigs (return_catch);
+ }
+
+ flags = SEVAL_NONINT|SEVAL_NOHIST;
+ if (sig != DEBUG_TRAP && sig != RETURN_TRAP && sig != ERROR_TRAP)
+ flags |= SEVAL_RESETLINE;
+ if (function_code == 0)
+ parse_and_execute (trap_command, tag, flags);
+
+ trap_exit_value = last_command_exit_value;
+
+#if defined (JOB_CONTROL)
+ if (sig != DEBUG_TRAP) /* run_debug_trap does this */
+ restore_pipeline (1);
+#endif
+
+ subst_assign_varlist = save_subst_varlist;
+ restore_parser_state (&pstate);
+
+#if defined (ARRAY_VARS)
+ restore_pipestatus_array (ps);
+#endif