bash: update to 4.4.23
This commit is contained in:
parent
3115fe08f4
commit
7adbfa647b
@ -7,7 +7,7 @@
|
|||||||
# Check the following 4 variables before running the script
|
# Check the following 4 variables before running the script
|
||||||
topdir=bash
|
topdir=bash
|
||||||
real_version=4.4
|
real_version=4.4
|
||||||
version=4.4.12
|
version=4.4.23
|
||||||
pkgver=1
|
pkgver=1
|
||||||
source[0]=ftp://ftp.sunet.se/pub/gnu/bash/$topdir-$real_version.tar.gz
|
source[0]=ftp://ftp.sunet.se/pub/gnu/bash/$topdir-$real_version.tar.gz
|
||||||
|
|
||||||
@ -27,6 +27,17 @@ patch[9]=bash44-009
|
|||||||
patch[10]=bash44-010
|
patch[10]=bash44-010
|
||||||
patch[11]=bash44-011
|
patch[11]=bash44-011
|
||||||
patch[12]=bash44-012
|
patch[12]=bash44-012
|
||||||
|
patch[13]=bash44-013
|
||||||
|
patch[14]=bash44-014
|
||||||
|
patch[15]=bash44-015
|
||||||
|
patch[16]=bash44-016
|
||||||
|
patch[17]=bash44-017
|
||||||
|
patch[18]=bash44-018
|
||||||
|
patch[19]=bash44-019
|
||||||
|
patch[20]=bash44-020
|
||||||
|
patch[21]=bash44-021
|
||||||
|
patch[22]=bash44-022
|
||||||
|
patch[23]=bash44-023
|
||||||
|
|
||||||
# Global settings
|
# Global settings
|
||||||
export CPPFLAGS="-I$prefix/include"
|
export CPPFLAGS="-I$prefix/include"
|
||||||
@ -69,6 +80,8 @@ install()
|
|||||||
compat bash 4.3.30 1 1
|
compat bash 4.3.30 1 1
|
||||||
compat bash 4.3.33 1 1
|
compat bash 4.3.33 1 1
|
||||||
compat bash 4.3.39 1 1
|
compat bash 4.3.39 1 1
|
||||||
|
compat bash 4.3.42 1 1
|
||||||
|
compat bash 4.4.12 1 1
|
||||||
}
|
}
|
||||||
|
|
||||||
reg pack
|
reg pack
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
CHANGELOG
|
CHANGELOG
|
||||||
---------
|
---------
|
||||||
|
* Sun Mar 24 2019 Tom G. Christensen <swpkg@jupiterrise.com> - 4.4.23-1
|
||||||
|
- Update to 4.4.23
|
||||||
|
|
||||||
* Sat Sep 30 2017 Tom G. Christensen <swpkg@jupiterrise.com> - 4.4.12-1
|
* Sat Sep 30 2017 Tom G. Christensen <swpkg@jupiterrise.com> - 4.4.12-1
|
||||||
- Update to 4.4.12
|
- Update to 4.4.12
|
||||||
|
|
||||||
|
43
bash/src/bash44-013
Normal file
43
bash/src/bash44-013
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-013
|
||||||
|
|
||||||
|
Bug-Reported-by: Siteshwar Vashisht <svashisht@redhat.com>
|
||||||
|
Bug-Reference-ID: <1508861265.9523642.1484659442561.JavaMail.zimbra@redhat.com>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2017-01/msg00026.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
If a here-document contains a command substitution, the command substitution
|
||||||
|
can get access to the file descriptor used to write the here-document.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4-patched/redir.c 2016-06-02 20:22:24.000000000 -0400
|
||||||
|
--- redir.c 2017-01-17 13:23:40.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 470,473 ****
|
||||||
|
--- 467,472 ----
|
||||||
|
}
|
||||||
|
|
||||||
|
+ SET_CLOSE_ON_EXEC (fd);
|
||||||
|
+
|
||||||
|
errno = r = 0; /* XXX */
|
||||||
|
/* write_here_document returns 0 on success, errno on failure. */
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 12
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 13
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
104
bash/src/bash44-014
Normal file
104
bash/src/bash44-014
Normal file
@ -0,0 +1,104 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-014
|
||||||
|
|
||||||
|
Bug-Reported-by: Oyvind Hvidsten <oyvind.hvidsten@dhampir.no>
|
||||||
|
Bug-Reference-ID: <c01b7049-925c-9409-d978-e59bf42591f4@dhampir.no>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2017-12/msg00023.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
Under some circumstances, functions that return via the `return' builtin do
|
||||||
|
not clean up memory they allocated to keep track of FIFOs.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-20171205/execute_cmd.c 2017-12-08 07:38:28.000000000 -0500
|
||||||
|
--- execute_cmd.c 2018-01-26 15:23:38.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 727,730 ****
|
||||||
|
--- 727,732 ----
|
||||||
|
ofifo = num_fifos ();
|
||||||
|
ofifo_list = copy_fifo_list ((int *)&osize);
|
||||||
|
+ begin_unwind_frame ("internal_fifos");
|
||||||
|
+ add_unwind_protect (xfree, ofifo_list);
|
||||||
|
saved_fifo = 1;
|
||||||
|
}
|
||||||
|
***************
|
||||||
|
*** 742,746 ****
|
||||||
|
#if defined (PROCESS_SUBSTITUTION)
|
||||||
|
if (saved_fifo)
|
||||||
|
! free ((void *)ofifo_list);
|
||||||
|
#endif
|
||||||
|
return (last_command_exit_value = EXECUTION_FAILURE);
|
||||||
|
--- 744,751 ----
|
||||||
|
#if defined (PROCESS_SUBSTITUTION)
|
||||||
|
if (saved_fifo)
|
||||||
|
! {
|
||||||
|
! free ((void *)ofifo_list);
|
||||||
|
! discard_unwind_frame ("internal_fifos");
|
||||||
|
! }
|
||||||
|
#endif
|
||||||
|
return (last_command_exit_value = EXECUTION_FAILURE);
|
||||||
|
***************
|
||||||
|
*** 1061,1064 ****
|
||||||
|
--- 1066,1070 ----
|
||||||
|
close_new_fifos ((char *)ofifo_list, osize);
|
||||||
|
free ((void *)ofifo_list);
|
||||||
|
+ discard_unwind_frame ("internal_fifos");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
***************
|
||||||
|
*** 4978,4984 ****
|
||||||
|
#endif
|
||||||
|
|
||||||
|
! #if defined (PROCESS_SUBSTITUTION)
|
||||||
|
ofifo = num_fifos ();
|
||||||
|
ofifo_list = copy_fifo_list (&osize);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
--- 4984,4995 ----
|
||||||
|
#endif
|
||||||
|
|
||||||
|
! #if defined (PROCESS_SUBSTITUTION)
|
||||||
|
! begin_unwind_frame ("saved_fifos");
|
||||||
|
! /* If we return, we longjmp and don't get a chance to restore the old
|
||||||
|
! fifo list, so we add an unwind protect to free it */
|
||||||
|
ofifo = num_fifos ();
|
||||||
|
ofifo_list = copy_fifo_list (&osize);
|
||||||
|
+ if (ofifo_list)
|
||||||
|
+ add_unwind_protect (xfree, ofifo_list);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
***************
|
||||||
|
*** 5064,5068 ****
|
||||||
|
if (nfifo > ofifo)
|
||||||
|
close_new_fifos (ofifo_list, osize);
|
||||||
|
! free (ofifo_list);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
--- 5075,5081 ----
|
||||||
|
if (nfifo > ofifo)
|
||||||
|
close_new_fifos (ofifo_list, osize);
|
||||||
|
! if (ofifo_list)
|
||||||
|
! free (ofifo_list);
|
||||||
|
! discard_unwind_frame ("saved_fifos");
|
||||||
|
#endif
|
||||||
|
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 13
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 14
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
43
bash/src/bash44-015
Normal file
43
bash/src/bash44-015
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-015
|
||||||
|
|
||||||
|
Bug-Reported-by: David Simmons <bug-bash@tmp.davidsimmons.com>
|
||||||
|
Bug-Reference-ID: <bc6f0839-fa50-fe8f-65f5-5aa6feb11ec5@davidsimmons.com>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2017-02/msg00033.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
Process substitution can leak internal quoting to the parser in the invoked
|
||||||
|
subshell.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-20170210/subst.c 2017-01-19 11:08:50.000000000 -0500
|
||||||
|
--- subst.c 2017-02-20 10:12:49.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 5907,5910 ****
|
||||||
|
--- 5907,5912 ----
|
||||||
|
expanding_redir = 0;
|
||||||
|
|
||||||
|
+ remove_quoted_escapes (string);
|
||||||
|
+
|
||||||
|
subshell_level++;
|
||||||
|
result = parse_and_execute (string, "process substitution", (SEVAL_NONINT|SEVAL_NOHIST));
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 14
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 15
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
78
bash/src/bash44-016
Normal file
78
bash/src/bash44-016
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-016
|
||||||
|
|
||||||
|
Bug-Reported-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
|
||||||
|
Bug-Reference-ID: <CAJq09z7G1-QnLyiUQA0DS=V3da_rtHF8VdYbbdzPe_W3kydpRg@mail.gmail.com>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2016-09/msg00092.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
Bash can perform trap processing while reading command substitution output
|
||||||
|
instead of waiting until the command completes.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4/lib/sh/zread.c 2014-12-22 10:48:04.000000000 -0500
|
||||||
|
--- lib/sh/zread.c 2016-09-29 15:21:36.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 38,42 ****
|
||||||
|
--- 38,45 ----
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+ extern int executing_builtin;
|
||||||
|
+
|
||||||
|
extern void check_signals_and_traps (void);
|
||||||
|
+ extern void check_signals (void);
|
||||||
|
extern int signal_is_trapped (int);
|
||||||
|
|
||||||
|
***************
|
||||||
|
*** 51,69 ****
|
||||||
|
ssize_t r;
|
||||||
|
|
||||||
|
- #if 0
|
||||||
|
- #if defined (HAVE_SIGINTERRUPT)
|
||||||
|
- if (signal_is_trapped (SIGCHLD))
|
||||||
|
- siginterrupt (SIGCHLD, 1);
|
||||||
|
- #endif
|
||||||
|
- #endif
|
||||||
|
-
|
||||||
|
while ((r = read (fd, buf, len)) < 0 && errno == EINTR)
|
||||||
|
! check_signals_and_traps (); /* XXX - should it be check_signals()? */
|
||||||
|
!
|
||||||
|
! #if 0
|
||||||
|
! #if defined (HAVE_SIGINTERRUPT)
|
||||||
|
! siginterrupt (SIGCHLD, 0);
|
||||||
|
! #endif
|
||||||
|
! #endif
|
||||||
|
|
||||||
|
return r;
|
||||||
|
--- 54,64 ----
|
||||||
|
ssize_t r;
|
||||||
|
|
||||||
|
while ((r = read (fd, buf, len)) < 0 && errno == EINTR)
|
||||||
|
! /* XXX - bash-5.0 */
|
||||||
|
! /* We check executing_builtin and run traps here for backwards compatibility */
|
||||||
|
! if (executing_builtin)
|
||||||
|
! check_signals_and_traps (); /* XXX - should it be check_signals()? */
|
||||||
|
! else
|
||||||
|
! check_signals ();
|
||||||
|
|
||||||
|
return r;
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 15
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 16
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
45
bash/src/bash44-017
Normal file
45
bash/src/bash44-017
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-017
|
||||||
|
|
||||||
|
Bug-Reported-by: ZhangXiao <xiao.zhang@windriver.com>
|
||||||
|
Bug-Reference-ID: <58AD3EAC.4020608@windriver.com>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2017-02/msg00061.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
There is a memory leak when `read -e' is used to read a line using readline.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-20170217/builtins/read.def 2017-01-02 16:53:02.000000000 -0500
|
||||||
|
--- builtins/read.def 2017-02-22 09:43:14.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 691,694 ****
|
||||||
|
--- 691,699 ----
|
||||||
|
CHECK_ALRM;
|
||||||
|
|
||||||
|
+ #if defined (READLINE)
|
||||||
|
+ if (edit)
|
||||||
|
+ free (rlbuf);
|
||||||
|
+ #endif
|
||||||
|
+
|
||||||
|
if (retval < 0)
|
||||||
|
{
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 16
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 17
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
48
bash/src/bash44-018
Normal file
48
bash/src/bash44-018
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-018
|
||||||
|
|
||||||
|
Bug-Reported-by: Siteshwar Vashisht <svashisht@redhat.com>
|
||||||
|
Bug-Reference-ID: <1341922391.30876471.1501250355579.JavaMail.zimbra@redhat.com>
|
||||||
|
Bug-Reference-URL: https://bugzilla.redhat.com/show_bug.cgi?id=1466737
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
Under certain circumstances (e.g., reading from /dev/zero), read(2) will not
|
||||||
|
return -1 even when interrupted by a signal. The read builtin needs to check
|
||||||
|
for signals in this case.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-20170622/builtins/read.def 2017-06-17 18:45:20.000000000 -0400
|
||||||
|
--- builtins/read.def 2017-06-30 11:09:26.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 611,615 ****
|
||||||
|
|
||||||
|
CHECK_ALRM;
|
||||||
|
!
|
||||||
|
#if defined (READLINE)
|
||||||
|
}
|
||||||
|
--- 611,615 ----
|
||||||
|
|
||||||
|
CHECK_ALRM;
|
||||||
|
! QUIT; /* in case we didn't call check_signals() */
|
||||||
|
#if defined (READLINE)
|
||||||
|
}
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 17
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 18
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
50
bash/src/bash44-019
Normal file
50
bash/src/bash44-019
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-019
|
||||||
|
|
||||||
|
Bug-Reported-by: Kieran Grant <kieran.thehacker.grant@gmail.com>
|
||||||
|
Bug-Reference-ID: <ec9071ae-efb1-9e09-5d03-e905daf2835c@gmail.com>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2018-02/msg00002.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
With certain values for PS1, especially those that wrap onto three or more
|
||||||
|
lines, readline will miscalculate the number of invisible characters,
|
||||||
|
leading to crashes and core dumps.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4.18/lib/readline/display.c 2016-07-28 14:49:33.000000000 -0400
|
||||||
|
--- lib/readline/display.c 2018-02-03 19:19:35.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 772,776 ****
|
||||||
|
wadjust = (newlines == 0)
|
||||||
|
? prompt_invis_chars_first_line
|
||||||
|
! : ((newlines == prompt_lines_estimate) ? wrap_offset : prompt_invis_chars_first_line);
|
||||||
|
|
||||||
|
/* fix from Darin Johnson <darin@acuson.com> for prompt string with
|
||||||
|
--- 788,794 ----
|
||||||
|
wadjust = (newlines == 0)
|
||||||
|
? prompt_invis_chars_first_line
|
||||||
|
! : ((newlines == prompt_lines_estimate)
|
||||||
|
! ? (wrap_offset - prompt_invis_chars_first_line)
|
||||||
|
! : 0);
|
||||||
|
|
||||||
|
/* fix from Darin Johnson <darin@acuson.com> for prompt string with
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 18
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 19
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
177
bash/src/bash44-020
Normal file
177
bash/src/bash44-020
Normal file
@ -0,0 +1,177 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-020
|
||||||
|
|
||||||
|
Bug-Reported-by: Graham Northup <northug@clarkson.edu>
|
||||||
|
Bug-Reference-ID: <537530c3-61f0-349b-9de6-fa4e2487f428@clarkson.edu>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2017-02/msg00025.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
In circumstances involving long-running scripts that create and reap many
|
||||||
|
processes, it is possible for the hash table bash uses to store exit
|
||||||
|
statuses from asynchronous processes to develop loops. This patch fixes
|
||||||
|
the loop causes and adds code to detect any future loops.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4-patched/jobs.c 2016-11-11 13:42:55.000000000 -0500
|
||||||
|
--- jobs.c 2017-02-22 15:16:28.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 813,818 ****
|
||||||
|
struct pidstat *ps;
|
||||||
|
|
||||||
|
! bucket = pshash_getbucket (pid);
|
||||||
|
! psi = bgp_getindex ();
|
||||||
|
ps = &bgpids.storage[psi];
|
||||||
|
|
||||||
|
--- 796,815 ----
|
||||||
|
struct pidstat *ps;
|
||||||
|
|
||||||
|
! /* bucket == existing chain of pids hashing to same value
|
||||||
|
! psi = where were going to put this pid/status */
|
||||||
|
!
|
||||||
|
! bucket = pshash_getbucket (pid); /* index into pidstat_table */
|
||||||
|
! psi = bgp_getindex (); /* bgpids.head, index into storage */
|
||||||
|
!
|
||||||
|
! /* XXX - what if psi == *bucket? */
|
||||||
|
! if (psi == *bucket)
|
||||||
|
! {
|
||||||
|
! #ifdef DEBUG
|
||||||
|
! internal_warning ("hashed pid %d (pid %d) collides with bgpids.head, skipping", psi, pid);
|
||||||
|
! #endif
|
||||||
|
! bgpids.storage[psi].pid = NO_PID; /* make sure */
|
||||||
|
! psi = bgp_getindex (); /* skip to next one */
|
||||||
|
! }
|
||||||
|
!
|
||||||
|
ps = &bgpids.storage[psi];
|
||||||
|
|
||||||
|
***************
|
||||||
|
*** 842,845 ****
|
||||||
|
--- 839,843 ----
|
||||||
|
{
|
||||||
|
struct pidstat *ps;
|
||||||
|
+ ps_index_t *bucket;
|
||||||
|
|
||||||
|
ps = &bgpids.storage[psi];
|
||||||
|
***************
|
||||||
|
*** 847,856 ****
|
||||||
|
return;
|
||||||
|
|
||||||
|
! if (ps->bucket_next != NO_PID)
|
||||||
|
bgpids.storage[ps->bucket_next].bucket_prev = ps->bucket_prev;
|
||||||
|
! if (ps->bucket_prev != NO_PID)
|
||||||
|
bgpids.storage[ps->bucket_prev].bucket_next = ps->bucket_next;
|
||||||
|
else
|
||||||
|
! *(pshash_getbucket (ps->pid)) = ps->bucket_next;
|
||||||
|
}
|
||||||
|
|
||||||
|
--- 845,861 ----
|
||||||
|
return;
|
||||||
|
|
||||||
|
! if (ps->bucket_next != NO_PIDSTAT)
|
||||||
|
bgpids.storage[ps->bucket_next].bucket_prev = ps->bucket_prev;
|
||||||
|
! if (ps->bucket_prev != NO_PIDSTAT)
|
||||||
|
bgpids.storage[ps->bucket_prev].bucket_next = ps->bucket_next;
|
||||||
|
else
|
||||||
|
! {
|
||||||
|
! bucket = pshash_getbucket (ps->pid);
|
||||||
|
! *bucket = ps->bucket_next; /* deleting chain head in hash table */
|
||||||
|
! }
|
||||||
|
!
|
||||||
|
! /* clear out this cell, just in case */
|
||||||
|
! ps->pid = NO_PID;
|
||||||
|
! ps->bucket_next = ps->bucket_prev = NO_PIDSTAT;
|
||||||
|
}
|
||||||
|
|
||||||
|
***************
|
||||||
|
*** 859,863 ****
|
||||||
|
pid_t pid;
|
||||||
|
{
|
||||||
|
! ps_index_t psi;
|
||||||
|
|
||||||
|
if (bgpids.storage == 0 || bgpids.nalloc == 0 || bgpids.npid == 0)
|
||||||
|
--- 864,868 ----
|
||||||
|
pid_t pid;
|
||||||
|
{
|
||||||
|
! ps_index_t psi, orig_psi;
|
||||||
|
|
||||||
|
if (bgpids.storage == 0 || bgpids.nalloc == 0 || bgpids.npid == 0)
|
||||||
|
***************
|
||||||
|
*** 865,871 ****
|
||||||
|
|
||||||
|
/* Search chain using hash to find bucket in pidstat_table */
|
||||||
|
! for (psi = *(pshash_getbucket (pid)); psi != NO_PIDSTAT; psi = bgpids.storage[psi].bucket_next)
|
||||||
|
! if (bgpids.storage[psi].pid == pid)
|
||||||
|
! break;
|
||||||
|
|
||||||
|
if (psi == NO_PIDSTAT)
|
||||||
|
--- 870,883 ----
|
||||||
|
|
||||||
|
/* Search chain using hash to find bucket in pidstat_table */
|
||||||
|
! for (orig_psi = psi = *(pshash_getbucket (pid)); psi != NO_PIDSTAT; psi = bgpids.storage[psi].bucket_next)
|
||||||
|
! {
|
||||||
|
! if (bgpids.storage[psi].pid == pid)
|
||||||
|
! break;
|
||||||
|
! if (orig_psi == bgpids.storage[psi].bucket_next) /* catch reported bug */
|
||||||
|
! {
|
||||||
|
! internal_warning ("bgp_delete: LOOP: psi (%d) == storage[psi].bucket_next", psi);
|
||||||
|
! return 0;
|
||||||
|
! }
|
||||||
|
! }
|
||||||
|
|
||||||
|
if (psi == NO_PIDSTAT)
|
||||||
|
***************
|
||||||
|
*** 905,909 ****
|
||||||
|
pid_t pid;
|
||||||
|
{
|
||||||
|
! ps_index_t psi;
|
||||||
|
|
||||||
|
if (bgpids.storage == 0 || bgpids.nalloc == 0 || bgpids.npid == 0)
|
||||||
|
--- 917,921 ----
|
||||||
|
pid_t pid;
|
||||||
|
{
|
||||||
|
! ps_index_t psi, orig_psi;
|
||||||
|
|
||||||
|
if (bgpids.storage == 0 || bgpids.nalloc == 0 || bgpids.npid == 0)
|
||||||
|
***************
|
||||||
|
*** 911,917 ****
|
||||||
|
|
||||||
|
/* Search chain using hash to find bucket in pidstat_table */
|
||||||
|
! for (psi = *(pshash_getbucket (pid)); psi != NO_PIDSTAT; psi = bgpids.storage[psi].bucket_next)
|
||||||
|
! if (bgpids.storage[psi].pid == pid)
|
||||||
|
! return (bgpids.storage[psi].status);
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
--- 923,936 ----
|
||||||
|
|
||||||
|
/* Search chain using hash to find bucket in pidstat_table */
|
||||||
|
! for (orig_psi = psi = *(pshash_getbucket (pid)); psi != NO_PIDSTAT; psi = bgpids.storage[psi].bucket_next)
|
||||||
|
! {
|
||||||
|
! if (bgpids.storage[psi].pid == pid)
|
||||||
|
! return (bgpids.storage[psi].status);
|
||||||
|
! if (orig_psi == bgpids.storage[psi].bucket_next) /* catch reported bug */
|
||||||
|
! {
|
||||||
|
! internal_warning ("bgp_search: LOOP: psi (%d) == storage[psi].bucket_next", psi);
|
||||||
|
! return -1;
|
||||||
|
! }
|
||||||
|
! }
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 19
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 20
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
57
bash/src/bash44-021
Normal file
57
bash/src/bash44-021
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-021
|
||||||
|
|
||||||
|
Bug-Reported-by: werner@suse.de
|
||||||
|
Bug-Reference-ID: <201803281402.w2SE2VOa000476@noether.suse.de>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2018-03/msg00196.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
A SIGINT received inside a SIGINT trap handler can possibly cause the
|
||||||
|
shell to loop.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-20180329/jobs.c 2018-02-11 18:07:22.000000000 -0500
|
||||||
|
--- jobs.c 2018-04-02 14:24:21.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 2690,2694 ****
|
||||||
|
if (job_control == 0 || (subshell_environment&SUBSHELL_COMSUB))
|
||||||
|
{
|
||||||
|
! old_sigint_handler = set_signal_handler (SIGINT, wait_sigint_handler);
|
||||||
|
waiting_for_child = 0;
|
||||||
|
if (old_sigint_handler == SIG_IGN)
|
||||||
|
--- 2690,2704 ----
|
||||||
|
if (job_control == 0 || (subshell_environment&SUBSHELL_COMSUB))
|
||||||
|
{
|
||||||
|
! SigHandler *temp_sigint_handler;
|
||||||
|
!
|
||||||
|
! temp_sigint_handler = set_signal_handler (SIGINT, wait_sigint_handler);
|
||||||
|
! if (temp_sigint_handler == wait_sigint_handler)
|
||||||
|
! {
|
||||||
|
! #if defined (DEBUG)
|
||||||
|
! internal_warning ("wait_for: recursively setting old_sigint_handler to wait_sigint_handler: running_trap = %d", running_trap);
|
||||||
|
! #endif
|
||||||
|
! }
|
||||||
|
! else
|
||||||
|
! old_sigint_handler = temp_sigint_handler;
|
||||||
|
waiting_for_child = 0;
|
||||||
|
if (old_sigint_handler == SIG_IGN)
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 20
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 21
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
61
bash/src/bash44-022
Normal file
61
bash/src/bash44-022
Normal file
@ -0,0 +1,61 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-022
|
||||||
|
|
||||||
|
Bug-Reported-by: Nuzhna Pomoshch <nuzhna_pomoshch@yahoo.com>
|
||||||
|
Bug-Reference-ID: <1317167476.1492079.1495999776464@mail.yahoo.com>
|
||||||
|
Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-readline/2017-05/msg00005.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
There are cases where a failing readline command (e.g., delete-char at the end
|
||||||
|
of a line) can cause a multi-character key sequence to `back up' and attempt
|
||||||
|
to re-read some of the characters in the sequence.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4-patched/lib/readline/readline.c 2016-04-20 15:53:52.000000000 -0400
|
||||||
|
--- lib/readline/readline.c 2018-05-26 17:19:00.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 1058,1062 ****
|
||||||
|
r = _rl_dispatch (ANYOTHERKEY, m);
|
||||||
|
}
|
||||||
|
! else if (r && map[ANYOTHERKEY].function)
|
||||||
|
{
|
||||||
|
/* We didn't match (r is probably -1), so return something to
|
||||||
|
--- 1056,1060 ----
|
||||||
|
r = _rl_dispatch (ANYOTHERKEY, m);
|
||||||
|
}
|
||||||
|
! else if (r < 0 && map[ANYOTHERKEY].function)
|
||||||
|
{
|
||||||
|
/* We didn't match (r is probably -1), so return something to
|
||||||
|
***************
|
||||||
|
*** 1070,1074 ****
|
||||||
|
return -2;
|
||||||
|
}
|
||||||
|
! else if (r && got_subseq)
|
||||||
|
{
|
||||||
|
/* OK, back up the chain. */
|
||||||
|
--- 1068,1072 ----
|
||||||
|
return -2;
|
||||||
|
}
|
||||||
|
! else if (r < 0 && got_subseq) /* XXX */
|
||||||
|
{
|
||||||
|
/* OK, back up the chain. */
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 21
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 22
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
52
bash/src/bash44-023
Normal file
52
bash/src/bash44-023
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
BASH PATCH REPORT
|
||||||
|
=================
|
||||||
|
|
||||||
|
Bash-Release: 4.4
|
||||||
|
Patch-ID: bash44-023
|
||||||
|
|
||||||
|
Bug-Reported-by: Martijn Dekker <martijn@inlv.org>
|
||||||
|
Bug-Reference-ID: <5326d6b9-2625-1d32-3e6e-ad1d15462c09@inlv.org>
|
||||||
|
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2016-11/msg00041.html
|
||||||
|
|
||||||
|
Bug-Description:
|
||||||
|
|
||||||
|
When sourcing a file from an interactive shell, setting the SIGINT handler
|
||||||
|
to the default and typing ^C will cause the shell to exit.
|
||||||
|
|
||||||
|
Patch (apply with `patch -p0'):
|
||||||
|
|
||||||
|
*** ../bash-4.4-patched/builtins/trap.def 2016-01-25 13:32:38.000000000 -0500
|
||||||
|
--- builtins/trap.def 2016-11-06 12:04:35.000000000 -0500
|
||||||
|
***************
|
||||||
|
*** 99,102 ****
|
||||||
|
--- 99,103 ----
|
||||||
|
|
||||||
|
extern int posixly_correct, subshell_environment;
|
||||||
|
+ extern int sourcelevel, running_trap;
|
||||||
|
|
||||||
|
int
|
||||||
|
***************
|
||||||
|
*** 213,216 ****
|
||||||
|
--- 214,220 ----
|
||||||
|
if (interactive)
|
||||||
|
set_signal_handler (SIGINT, sigint_sighandler);
|
||||||
|
+ /* special cases for interactive == 0 */
|
||||||
|
+ else if (interactive_shell && (sourcelevel||running_trap))
|
||||||
|
+ set_signal_handler (SIGINT, sigint_sighandler);
|
||||||
|
else
|
||||||
|
set_signal_handler (SIGINT, termsig_sighandler);
|
||||||
|
*** ../bash-4.4/patchlevel.h 2016-06-22 14:51:03.000000000 -0400
|
||||||
|
--- patchlevel.h 2016-10-01 11:01:28.000000000 -0400
|
||||||
|
***************
|
||||||
|
*** 26,30 ****
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 22
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
||||||
|
--- 26,30 ----
|
||||||
|
looks for to find the patch level (for the sccs version string). */
|
||||||
|
|
||||||
|
! #define PATCHLEVEL 23
|
||||||
|
|
||||||
|
#endif /* _PATCHLEVEL_H_ */
|
Loading…
x
Reference in New Issue
Block a user