7 Bug-Reported-by: Mark March <march@systempad.cloud>
8 Bug-Reference-ID: <834896722.6304071.1718744118467@mail.yahoo.com>
9 Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2024-06/msg00122.html
13 A DEBUG trap in an asynchronous process can steal the controlling terminal
14 away from the calling shell, causing it to exit.
16 Patch (apply with `patch -p0'):
18 *** ../bash-20240609/trap.c Fri May 3 12:12:38 2024
19 --- trap.c Wed Jun 26 10:41:40 2024
22 restore_pgrp_pipe (save_pipe);
24 ! if (pipeline_pgrp > 0 && ((subshell_environment & (SUBSHELL_ASYNC|SUBSHELL_PIPE)) == 0))
25 give_terminal_to (pipeline_pgrp, 1);
28 restore_pgrp_pipe (save_pipe);
30 ! /* If the trap command gave the terminal to another process group,
31 ! restore it. XXX - check running_in_background? */
32 ! if (job_control && pipeline_pgrp > 0 && ((subshell_environment & (SUBSHELL_ASYNC|SUBSHELL_PIPE)) == 0))
33 give_terminal_to (pipeline_pgrp, 1);
35 *** ../bash-5.2/patchlevel.h 2020-06-22 14:51:03.000000000 -0400
36 --- patchlevel.h 2020-10-01 11:01:28.000000000 -0400
39 looks for to find the patch level (for the sccs version string). */
41 ! #define PATCHLEVEL 27
43 #endif /* _PATCHLEVEL_H_ */
45 looks for to find the patch level (for the sccs version string). */
47 ! #define PATCHLEVEL 28
49 #endif /* _PATCHLEVEL_H_ */