			     BASH PATCH REPORT
			     =================

Bash-Release:	5.1
Patch-ID:	bash51-006

Bug-Reported-by:	oguzismailuysal@gmail.com
Bug-Reference-ID:	<CAH7i3LoY7C+pV_yG2LxwPNtAw3kiRkxmB4KcL1dTsih0u2BdKA@mail.gmail.com>
Bug-Reference-URL:	https://lists.gnu.org/archive/html/bug-bash/2020-12/msg00108.html

Bug-Description:

Make sure child processes forked to run command substitutions are in the
proper process group.

Patch (apply with `patch -p0'):

*** ../bash-5.1-patched/subst.c	2020-12-16 17:01:32.000000000 -0500
--- subst.c	2020-12-25 19:20:25.000000000 -0500
***************
*** 6413,6416 ****
--- 6413,6423 ----
        interactive = 0;
  
+ #if defined (JOB_CONTROL)
+       /* Invariant: in child processes started to run command substitutions,
+ 	 pipeline_pgrp == shell_pgrp. Other parts of the shell assume this. */
+       if (pipeline_pgrp > 0 && pipeline_pgrp != shell_pgrp)
+ 	shell_pgrp = pipeline_pgrp;
+ #endif
+ 
        set_sigint_handler ();	/* XXX */
  
*** ../bash-5.1/patchlevel.h	2020-06-22 14:51:03.000000000 -0400
--- patchlevel.h	2020-10-01 11:01:28.000000000 -0400
***************
*** 26,30 ****
     looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 5
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 ----
     looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 6
  
  #endif /* _PATCHLEVEL_H_ */
