1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
|
Bash-Release: 4.4
Patch-ID: bash44-005
Bug-Reported-by: Dr. Werner Fink <werner@suse.de>
Bug-Reference-ID: <20161107100936.ajnojd7dspirdflf@noether.suse.de>
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2016-11/msg00054.html
Bug-Description:
Under certain circumstances, a simple command is optimized to eliminate a
fork, resulting in an EXIT trap not being executed.
Index: b/builtins/evalstring.c
===================================================================
--- a/builtins/evalstring.c
+++ b/builtins/evalstring.c
@@ -104,12 +104,9 @@ should_suppress_fork (command)
running_trap == 0 &&
*bash_input.location.string == '\0' &&
command->type == cm_simple &&
-#if 0
signal_is_trapped (EXIT_TRAP) == 0 &&
signal_is_trapped (ERROR_TRAP) == 0 &&
-#else
any_signals_trapped () < 0 &&
-#endif
command->redirects == 0 && command->value.Simple->redirects == 0 &&
((command->flags & CMD_TIME_PIPELINE) == 0) &&
((command->flags & CMD_INVERT_RETURN) == 0));
Index: b/patchlevel.h
===================================================================
--- a/patchlevel.h
+++ b/patchlevel.h
@@ -25,6 +25,6 @@
regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh
looks for to find the patch level (for the sccs version string). */
-#define PATCHLEVEL 4
+#define PATCHLEVEL 5
#endif /* _PATCHLEVEL_H_ */
|