102-upstream-bash43-002.patch 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. BASH PATCH REPORT
  2. =================
  3. Bash-Release: 4.3
  4. Patch-ID: bash43-002
  5. Bug-Reported-by: Moe Tunes <moetunes42@gmail.com>
  6. Bug-Reference-ID: <53103F49.3070100@gmail.com>
  7. Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2014-02/msg00086.html
  8. Bug-Description:
  9. A change to save state while running the DEBUG trap caused pipelines to hang
  10. on systems which need process group synchronization while building pipelines.
  11. Patch (apply with `patch -p0'):
  12. --- a/trap.c
  13. +++ b/trap.c
  14. @@ -920,7 +920,8 @@ _run_trap_internal (sig, tag)
  15. subst_assign_varlist = 0;
  16. #if defined (JOB_CONTROL)
  17. - save_pipeline (1); /* XXX only provides one save level */
  18. + if (sig != DEBUG_TRAP) /* run_debug_trap does this */
  19. + save_pipeline (1); /* XXX only provides one save level */
  20. #endif
  21. /* If we're in a function, make sure return longjmps come here, too. */
  22. @@ -940,7 +941,8 @@ _run_trap_internal (sig, tag)
  23. trap_exit_value = last_command_exit_value;
  24. #if defined (JOB_CONTROL)
  25. - restore_pipeline (1);
  26. + if (sig != DEBUG_TRAP) /* run_debug_trap does this */
  27. + restore_pipeline (1);
  28. #endif
  29. subst_assign_varlist = save_subst_varlist;
  30. --- a/patchlevel.h
  31. +++ b/patchlevel.h
  32. @@ -25,6 +25,6 @@
  33. regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh
  34. looks for to find the patch level (for the sccs version string). */
  35. -#define PATCHLEVEL 1
  36. +#define PATCHLEVEL 2
  37. #endif /* _PATCHLEVEL_H_ */