From 446d1ba43ebeace1e7ad7011a290a9ceb36441c2 Mon Sep 17 00:00:00 2001 From: Idris Kalp Date: Mon, 1 Mar 2021 22:51:00 +0300 Subject: [PATCH] bash 5.1.p4 --- .../files/official/bash-4.4-patch-1.patch | 49 --- .../files/official/bash-4.4-patch-10.patch | 39 --- .../files/official/bash-4.4-patch-11.patch | 39 --- .../files/official/bash-4.4-patch-12.patch | 119 -------- .../files/official/bash-4.4-patch-13.patch | 38 --- .../files/official/bash-4.4-patch-14.patch | 85 ------ .../files/official/bash-4.4-patch-15.patch | 38 --- .../files/official/bash-4.4-patch-16.patch | 68 ----- .../files/official/bash-4.4-patch-17.patch | 41 --- .../files/official/bash-4.4-patch-18.patch | 38 --- .../files/official/bash-4.4-patch-19.patch | 40 --- .../files/official/bash-4.4-patch-2.patch | 59 ---- .../files/official/bash-4.4-patch-3.patch | 52 ---- .../files/official/bash-4.4-patch-4.patch | 81 ----- .../files/official/bash-4.4-patch-5.patch | 42 --- .../files/official/bash-4.4-patch-6.patch | 50 --- .../files/official/bash-4.4-patch-7.patch | 114 ------- .../files/official/bash-4.4-patch-8.patch | 71 ----- .../files/official/bash-4.4-patch-9.patch | 80 ----- .../bash/files/official/bash43-031.tar.gz | Bin 1452 -> 0 bytes .../bash/files/official/bash43-032.tar.gz | Bin 937 -> 0 bytes .../bash/files/official/bash43-033.tar.gz | Bin 2612 -> 0 bytes .../bash/files/official/bash43-034.tar.gz | Bin 1087 -> 0 bytes .../bash/files/official/bash43-035.tar.gz | Bin 879 -> 0 bytes .../bash/files/official/bash43-036.tar.gz | Bin 822 -> 0 bytes .../bash/files/official/bash43-037.tar.gz | Bin 752 -> 0 bytes .../bash/files/official/bash43-038.tar.gz | Bin 871 -> 0 bytes .../bash/files/official/bash43-039.tar.gz | Bin 851 -> 0 bytes .../bash/files/official/bash43-040.tar.gz | Bin 797 -> 0 bytes .../bash/files/official/bash43-041.tar.gz | Bin 1163 -> 0 bytes .../bash/files/official/bash43-042.tar.gz | Bin 747 -> 0 bytes .../bash/files/official/bash43-043.tar.gz | Bin 934 -> 0 bytes .../bash/files/official/bash43-044.tar.gz | Bin 730 -> 0 bytes .../bash/files/official/bash43-045.tar.gz | Bin 734 -> 0 bytes .../bash/files/official/bash43-046.tar.gz | Bin 818 -> 0 bytes .../bash/files/official/bash43-047.tar.gz | Bin 1288 -> 0 bytes .../bash/files/official/bash43-048.tar.gz | Bin 853 -> 0 bytes .../base/bash/files/official/bash50-001.patch | 166 ---------- .../base/bash/files/official/bash50-002.patch | 113 ------- .../base/bash/files/official/bash50-003.patch | 239 --------------- .../base/bash/files/official/bash50-004.patch | 53 ---- .../base/bash/files/official/bash50-005.patch | 110 ------- .../base/bash/files/official/bash50-006.patch | 47 --- .../base/bash/files/official/bash50-007.patch | 62 ---- .../base/bash/files/official/bash50-008.patch | 68 ----- .../base/bash/files/official/bash50-009.patch | 42 --- .../base/bash/files/official/bash50-010.patch | 172 ----------- .../base/bash/files/official/bash50-011.patch | 59 ---- .../base/bash/files/official/bash50-012.patch | 64 ---- .../base/bash/files/official/bash50-013.patch | 73 ----- .../base/bash/files/official/bash50-014.patch | 52 ---- .../base/bash/files/official/bash50-015.patch | 78 ----- .../base/bash/files/official/bash50-016.patch | 58 ---- .../base/bash/files/official/bash50-017.patch | 289 ------------------ .../base/bash/files/official/bash50-018.patch | 45 --- .../base/bash/files/official/bash51-001.patch | 80 +++++ .../base/bash/files/official/bash51-002.patch | 57 ++++ .../base/bash/files/official/bash51-003.patch | 53 ++++ .../base/bash/files/official/bash51-004.patch | 126 ++++++++ system/base/bash/pspec.xml | 33 +- 60 files changed, 329 insertions(+), 2953 deletions(-) delete mode 100644 system/base/bash/files/official/bash-4.4-patch-1.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-10.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-11.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-12.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-13.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-14.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-15.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-16.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-17.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-18.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-19.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-2.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-3.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-4.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-5.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-6.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-7.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-8.patch delete mode 100644 system/base/bash/files/official/bash-4.4-patch-9.patch delete mode 100644 system/base/bash/files/official/bash43-031.tar.gz delete mode 100644 system/base/bash/files/official/bash43-032.tar.gz delete mode 100644 system/base/bash/files/official/bash43-033.tar.gz delete mode 100644 system/base/bash/files/official/bash43-034.tar.gz delete mode 100644 system/base/bash/files/official/bash43-035.tar.gz delete mode 100644 system/base/bash/files/official/bash43-036.tar.gz delete mode 100644 system/base/bash/files/official/bash43-037.tar.gz delete mode 100644 system/base/bash/files/official/bash43-038.tar.gz delete mode 100644 system/base/bash/files/official/bash43-039.tar.gz delete mode 100644 system/base/bash/files/official/bash43-040.tar.gz delete mode 100644 system/base/bash/files/official/bash43-041.tar.gz delete mode 100644 system/base/bash/files/official/bash43-042.tar.gz delete mode 100644 system/base/bash/files/official/bash43-043.tar.gz delete mode 100644 system/base/bash/files/official/bash43-044.tar.gz delete mode 100644 system/base/bash/files/official/bash43-045.tar.gz delete mode 100644 system/base/bash/files/official/bash43-046.tar.gz delete mode 100644 system/base/bash/files/official/bash43-047.tar.gz delete mode 100644 system/base/bash/files/official/bash43-048.tar.gz delete mode 100644 system/base/bash/files/official/bash50-001.patch delete mode 100644 system/base/bash/files/official/bash50-002.patch delete mode 100644 system/base/bash/files/official/bash50-003.patch delete mode 100644 system/base/bash/files/official/bash50-004.patch delete mode 100644 system/base/bash/files/official/bash50-005.patch delete mode 100644 system/base/bash/files/official/bash50-006.patch delete mode 100644 system/base/bash/files/official/bash50-007.patch delete mode 100644 system/base/bash/files/official/bash50-008.patch delete mode 100644 system/base/bash/files/official/bash50-009.patch delete mode 100644 system/base/bash/files/official/bash50-010.patch delete mode 100644 system/base/bash/files/official/bash50-011.patch delete mode 100644 system/base/bash/files/official/bash50-012.patch delete mode 100644 system/base/bash/files/official/bash50-013.patch delete mode 100644 system/base/bash/files/official/bash50-014.patch delete mode 100644 system/base/bash/files/official/bash50-015.patch delete mode 100644 system/base/bash/files/official/bash50-016.patch delete mode 100644 system/base/bash/files/official/bash50-017.patch delete mode 100644 system/base/bash/files/official/bash50-018.patch create mode 100644 system/base/bash/files/official/bash51-001.patch create mode 100644 system/base/bash/files/official/bash51-002.patch create mode 100644 system/base/bash/files/official/bash51-003.patch create mode 100644 system/base/bash/files/official/bash51-004.patch diff --git a/system/base/bash/files/official/bash-4.4-patch-1.patch b/system/base/bash/files/official/bash-4.4-patch-1.patch deleted file mode 100644 index e0a60883..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-1.patch +++ /dev/null @@ -1,49 +0,0 @@ -From 8ddc8d6e3a3d85eec6d4ba9b9ed2bc36bce56716 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 14 Nov 2016 14:26:51 -0500 -Subject: [PATCH] Bash-4.4 patch 1 - ---- - lib/readline/history.c | 6 +++++- - patchlevel.h | 2 +- - 2 files changed, 6 insertions(+), 2 deletions(-) - -diff --git a/lib/readline/history.c b/lib/readline/history.c -index 3b8dbc5..9ff25a7 100644 ---- a/lib/readline/history.c -+++ b/lib/readline/history.c -@@ -57,6 +57,8 @@ extern int errno; - /* How big to make the_history when we first allocate it. */ - #define DEFAULT_HISTORY_INITIAL_SIZE 502 - -+#define MAX_HISTORY_INITIAL_SIZE 8192 -+ - /* The number of slots to increase the_history by. */ - #define DEFAULT_HISTORY_GROW_SIZE 50 - -@@ -307,7 +309,9 @@ add_history (string) - if (history_size == 0) - { - if (history_stifled && history_max_entries > 0) -- history_size = history_max_entries + 2; -+ history_size = (history_max_entries > MAX_HISTORY_INITIAL_SIZE) -+ ? MAX_HISTORY_INITIAL_SIZE -+ : history_max_entries + 2; - else - history_size = DEFAULT_HISTORY_INITIAL_SIZE; - the_history = (HIST_ENTRY **)xmalloc (history_size * sizeof (HIST_ENTRY *)); -diff --git a/patchlevel.h b/patchlevel.h -index 1cd7c96..40db1a3 100644 ---- 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 0 -+#define PATCHLEVEL 1 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-10.patch b/system/base/bash/files/official/bash-4.4-patch-10.patch deleted file mode 100644 index ec0fbfe5..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-10.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 5b9762d6f0cd36ff1b88bde22efa30ad0ed27ec6 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 15:38:38 -0500 -Subject: [PATCH] Bash-4.4 patch 10 - ---- - builtins/read.def | 3 ++- - patchlevel.h | 2 +- - 2 files changed, 3 insertions(+), 2 deletions(-) - -diff --git a/builtins/read.def b/builtins/read.def -index 48fda33..33821f3 100644 ---- a/builtins/read.def -+++ b/builtins/read.def -@@ -181,7 +181,8 @@ read_builtin (list) - WORD_LIST *list; - { - register char *varname; -- int size, i, nr, pass_next, saw_escape, eof, opt, retval, code, print_ps2; -+ int size, nr, pass_next, saw_escape, eof, opt, retval, code, print_ps2; -+ volatile int i; - int input_is_tty, input_is_pipe, unbuffered_read, skip_ctlesc, skip_ctlnul; - int raw, edit, nchars, silent, have_timeout, ignore_delim, fd, lastsig, t_errno; - unsigned int tmsec, tmusec; -diff --git a/patchlevel.h b/patchlevel.h -index 02f1d60..8002af7 100644 ---- 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 9 -+#define PATCHLEVEL 10 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-11.patch b/system/base/bash/files/official/bash-4.4-patch-11.patch deleted file mode 100644 index d3ec76aa..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-11.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 76bb456d8fcd870cd31b7bf9d90798cd97cee2ab Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 15:38:49 -0500 -Subject: [PATCH] Bash-4.4 patch 11 - ---- - patchlevel.h | 2 +- - sig.c | 3 ++- - 2 files changed, 3 insertions(+), 2 deletions(-) - -diff --git a/patchlevel.h b/patchlevel.h -index 8002af7..772676c 100644 ---- 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 10 -+#define PATCHLEVEL 11 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/sig.c b/sig.c -index ad01631..e5bb739 100644 ---- a/sig.c -+++ b/sig.c -@@ -585,7 +585,8 @@ termsig_handler (sig) - #if defined (JOB_CONTROL) - if (sig == SIGHUP && (interactive || (subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB)))) - hangup_all_jobs (); -- end_job_control (); -+ if ((subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB)) == 0) -+ end_job_control (); - #endif /* JOB_CONTROL */ - - #if defined (PROCESS_SUBSTITUTION) --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-12.patch b/system/base/bash/files/official/bash-4.4-patch-12.patch deleted file mode 100644 index 2983a947..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-12.patch +++ /dev/null @@ -1,119 +0,0 @@ -From bc007799f0e1362100375bb95d952d28de4c62fb Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 27 Jan 2017 11:25:44 -0500 -Subject: [PATCH] Bash-4.4 patch 12 - ---- - patchlevel.h | 2 +- - subst.c | 32 ++++++++++++++++++++------------ - 2 files changed, 21 insertions(+), 13 deletions(-) - -diff --git a/patchlevel.h b/patchlevel.h -index 772676c..93dbe0d 100644 ---- 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 11 -+#define PATCHLEVEL 12 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/subst.c b/subst.c -index 027a13e..dbf0157 100644 ---- a/subst.c -+++ b/subst.c -@@ -2825,11 +2825,15 @@ list_string (string, separators, quoted) - - /* Parse a single word from STRING, using SEPARATORS to separate fields. - ENDPTR is set to the first character after the word. This is used by -- the `read' builtin. This is never called with SEPARATORS != $IFS; -- it should be simplified. -+ the `read' builtin. -+ -+ This is never called with SEPARATORS != $IFS, and takes advantage of that. - - XXX - this function is very similar to list_string; they should be - combined - XXX */ -+ -+#define islocalsep(c) (local_cmap[(unsigned char)(c)] != 0) -+ - char * - get_word_from_string (stringp, separators, endptr) - char **stringp, *separators, **endptr; -@@ -2837,6 +2841,7 @@ get_word_from_string (stringp, separators, endptr) - register char *s; - char *current_word; - int sindex, sh_style_split, whitesep, xflags; -+ unsigned char local_cmap[UCHAR_MAX+1]; /* really only need single-byte chars here */ - size_t slen; - - if (!stringp || !*stringp || !**stringp) -@@ -2846,20 +2851,23 @@ get_word_from_string (stringp, separators, endptr) - separators[1] == '\t' && - separators[2] == '\n' && - separators[3] == '\0'; -- for (xflags = 0, s = ifs_value; s && *s; s++) -+ memset (local_cmap, '\0', sizeof (local_cmap)); -+ for (xflags = 0, s = separators; s && *s; s++) - { - if (*s == CTLESC) xflags |= SX_NOCTLESC; - if (*s == CTLNUL) xflags |= SX_NOESCCTLNUL; -+ local_cmap[(unsigned char)*s] = 1; /* local charmap of separators */ - } - - s = *stringp; - slen = 0; - - /* Remove sequences of whitespace at the beginning of STRING, as -- long as those characters appear in IFS. */ -- if (sh_style_split || !separators || !*separators) -+ long as those characters appear in SEPARATORS. This happens if -+ SEPARATORS == $' \t\n' or if IFS is unset. */ -+ if (sh_style_split || separators == 0) - { -- for (; *s && spctabnl (*s) && isifs (*s); s++); -+ for (; *s && spctabnl (*s) && islocalsep (*s); s++); - - /* If the string is nothing but whitespace, update it and return. */ - if (!*s) -@@ -2878,9 +2886,9 @@ get_word_from_string (stringp, separators, endptr) - - This obeys the field splitting rules in Posix.2. */ - sindex = 0; -- /* Don't need string length in ADVANCE_CHAR or string_extract_verbatim -- unless multibyte chars are possible. */ -- slen = (MB_CUR_MAX > 1) ? STRLEN (s) : 1; -+ /* Don't need string length in ADVANCE_CHAR unless multibyte chars are -+ possible, but need it in string_extract_verbatim for bounds checking */ -+ slen = STRLEN (s); - current_word = string_extract_verbatim (s, slen, &sindex, separators, xflags); - - /* Set ENDPTR to the first character after the end of the word. */ -@@ -2899,19 +2907,19 @@ get_word_from_string (stringp, separators, endptr) - - /* Now skip sequences of space, tab, or newline characters if they are - in the list of separators. */ -- while (s[sindex] && spctabnl (s[sindex]) && isifs (s[sindex])) -+ while (s[sindex] && spctabnl (s[sindex]) && islocalsep (s[sindex])) - sindex++; - - /* If the first separator was IFS whitespace and the current character is - a non-whitespace IFS character, it should be part of the current field - delimiter, not a separate delimiter that would result in an empty field. - Look at POSIX.2, 3.6.5, (3)(b). */ -- if (s[sindex] && whitesep && isifs (s[sindex]) && !spctabnl (s[sindex])) -+ if (s[sindex] && whitesep && islocalsep (s[sindex]) && !spctabnl (s[sindex])) - { - sindex++; - /* An IFS character that is not IFS white space, along with any adjacent - IFS white space, shall delimit a field. */ -- while (s[sindex] && spctabnl (s[sindex]) && isifs (s[sindex])) -+ while (s[sindex] && spctabnl (s[sindex]) && islocalsep(s[sindex])) - sindex++; - } - --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-13.patch b/system/base/bash/files/official/bash-4.4-patch-13.patch deleted file mode 100644 index abfb2def..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-13.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 1aef9c7b55dcef4af239caf93e01419e1c8e04ad Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:03:33 -0500 -Subject: [PATCH] Bash-4.4 patch 13 - ---- - patchlevel.h | 2 +- - redir.c | 2 ++ - 2 files changed, 3 insertions(+), 1 deletion(-) - -diff --git a/patchlevel.h b/patchlevel.h -index 93dbe0db..779671cd 100644 ---- 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 12 -+#define PATCHLEVEL 13 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/redir.c b/redir.c -index 25488eaf..1858b0b0 100644 ---- a/redir.c -+++ b/redir.c -@@ -469,6 +469,8 @@ here_document_to_fd (redirectee, ri) - return (fd); - } - -+ SET_CLOSE_ON_EXEC (fd); -+ - errno = r = 0; /* XXX */ - /* write_here_document returns 0 on success, errno on failure. */ - if (redirectee->word) --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-14.patch b/system/base/bash/files/official/bash-4.4-patch-14.patch deleted file mode 100644 index bceb8eaa..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-14.patch +++ /dev/null @@ -1,85 +0,0 @@ -From 2fb21d75bfddd724b0e45d4a51455a166467e496 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:03:47 -0500 -Subject: [PATCH] Bash-4.4 patch 14 - ---- - execute_cmd.c | 19 ++++++++++++++++--- - patchlevel.h | 2 +- - 2 files changed, 17 insertions(+), 4 deletions(-) - -diff --git a/execute_cmd.c b/execute_cmd.c -index 2a3df6d6..76a80766 100644 ---- a/execute_cmd.c -+++ b/execute_cmd.c -@@ -726,6 +726,8 @@ execute_command_internal (command, asynchronous, pipe_in, pipe_out, - { - ofifo = num_fifos (); - ofifo_list = copy_fifo_list ((int *)&osize); -+ begin_unwind_frame ("internal_fifos"); -+ add_unwind_protect (xfree, ofifo_list); - saved_fifo = 1; - } - else -@@ -741,7 +743,10 @@ execute_command_internal (command, asynchronous, pipe_in, pipe_out, - dispose_exec_redirects (); - #if defined (PROCESS_SUBSTITUTION) - if (saved_fifo) -- free ((void *)ofifo_list); -+ { -+ free ((void *)ofifo_list); -+ discard_unwind_frame ("internal_fifos"); -+ } - #endif - return (last_command_exit_value = EXECUTION_FAILURE); - } -@@ -1060,6 +1065,7 @@ execute_command_internal (command, asynchronous, pipe_in, pipe_out, - if (nfifo > ofifo) - close_new_fifos ((char *)ofifo_list, osize); - free ((void *)ofifo_list); -+ discard_unwind_frame ("internal_fifos"); - } - #endif - -@@ -4977,9 +4983,14 @@ execute_builtin_or_function (words, builtin, var, redirects, - char *ofifo_list; - #endif - --#if defined (PROCESS_SUBSTITUTION) -+#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 - - if (do_redirections (redirects, RX_ACTIVE|RX_UNDOABLE) != 0) -@@ -5063,7 +5074,9 @@ execute_builtin_or_function (words, builtin, var, redirects, - nfifo = num_fifos (); - if (nfifo > ofifo) - close_new_fifos (ofifo_list, osize); -- free (ofifo_list); -+ if (ofifo_list) -+ free (ofifo_list); -+ discard_unwind_frame ("saved_fifos"); - #endif - - return (result); -diff --git a/patchlevel.h b/patchlevel.h -index 779671cd..09a3cc84 100644 ---- 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 13 -+#define PATCHLEVEL 14 - - #endif /* _PATCHLEVEL_H_ */ --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-15.patch b/system/base/bash/files/official/bash-4.4-patch-15.patch deleted file mode 100644 index 7d1dccf0..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-15.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 9cce630e80008e74fa9a1d9408367341caf363f2 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:04:01 -0500 -Subject: [PATCH] Bash-4.4 patch 15 - ---- - patchlevel.h | 2 +- - subst.c | 2 ++ - 2 files changed, 3 insertions(+), 1 deletion(-) - -diff --git a/patchlevel.h b/patchlevel.h -index 09a3cc84..6e9ed3fc 100644 ---- 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 14 -+#define PATCHLEVEL 15 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/subst.c b/subst.c -index dbf0157e..fc00cab0 100644 ---- a/subst.c -+++ b/subst.c -@@ -5906,6 +5906,8 @@ process_substitute (string, open_for_read_in_child) - parent. */ - expanding_redir = 0; - -+ remove_quoted_escapes (string); -+ - subshell_level++; - result = parse_and_execute (string, "process substitution", (SEVAL_NONINT|SEVAL_NOHIST)); - subshell_level--; --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-16.patch b/system/base/bash/files/official/bash-4.4-patch-16.patch deleted file mode 100644 index 752b034e..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-16.patch +++ /dev/null @@ -1,68 +0,0 @@ -From c9f1b04651dae16e33f0aa8974c5122e26b362ae Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:04:20 -0500 -Subject: [PATCH] Bash-4.4 patch 16 - ---- - lib/sh/zread.c | 23 +++++++++-------------- - patchlevel.h | 2 +- - 2 files changed, 10 insertions(+), 15 deletions(-) - -diff --git a/lib/sh/zread.c b/lib/sh/zread.c -index 868f9705..496f20b8 100644 ---- a/lib/sh/zread.c -+++ b/lib/sh/zread.c -@@ -37,7 +37,10 @@ extern int errno; - # define SEEK_CUR 1 - #endif - -+extern int executing_builtin; -+ - extern void check_signals_and_traps (void); -+extern void check_signals (void); - extern int signal_is_trapped (int); - - /* Read LEN bytes from FD into BUF. Retry the read on EINTR. Any other -@@ -50,21 +53,13 @@ zread (fd, buf, len) - { - 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 -+ /* 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; - } -diff --git a/patchlevel.h b/patchlevel.h -index 6e9ed3fc..9074f4dd 100644 ---- 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 15 -+#define PATCHLEVEL 16 - - #endif /* _PATCHLEVEL_H_ */ --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-17.patch b/system/base/bash/files/official/bash-4.4-patch-17.patch deleted file mode 100644 index ac3eac87..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-17.patch +++ /dev/null @@ -1,41 +0,0 @@ -From b3a5ec8dd510a68dc850f3f516c0cf9afd87451f Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:04:37 -0500 -Subject: [PATCH] Bash-4.4 patch 17 - ---- - builtins/read.def | 5 +++++ - patchlevel.h | 2 +- - 2 files changed, 6 insertions(+), 1 deletion(-) - -diff --git a/builtins/read.def b/builtins/read.def -index 33821f3f..803bea35 100644 ---- a/builtins/read.def -+++ b/builtins/read.def -@@ -690,6 +690,11 @@ add_char: - input_string[i] = '\0'; - CHECK_ALRM; - -+#if defined (READLINE) -+ if (edit) -+ free (rlbuf); -+#endif -+ - if (retval < 0) - { - t_errno = errno; -diff --git a/patchlevel.h b/patchlevel.h -index 9074f4dd..98e714da 100644 ---- 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 16 -+#define PATCHLEVEL 17 - - #endif /* _PATCHLEVEL_H_ */ --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-18.patch b/system/base/bash/files/official/bash-4.4-patch-18.patch deleted file mode 100644 index 853a9e39..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-18.patch +++ /dev/null @@ -1,38 +0,0 @@ -From eb78197af36bb0fb95493ebf8fce104be6832ec9 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 29 Jan 2018 16:04:56 -0500 -Subject: [PATCH] Bash-4.4 patch 18 - ---- - builtins/read.def | 2 +- - patchlevel.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/builtins/read.def b/builtins/read.def -index 803bea35..b54b3af6 100644 ---- a/builtins/read.def -+++ b/builtins/read.def -@@ -610,7 +610,7 @@ read_builtin (list) - } - - CHECK_ALRM; -- -+ QUIT; /* in case we didn't call check_signals() */ - #if defined (READLINE) - } - #endif -diff --git a/patchlevel.h b/patchlevel.h -index 98e714da..f0ee56e4 100644 ---- 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 17 -+#define PATCHLEVEL 18 - - #endif /* _PATCHLEVEL_H_ */ --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-19.patch b/system/base/bash/files/official/bash-4.4-patch-19.patch deleted file mode 100644 index 35e66060..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-19.patch +++ /dev/null @@ -1,40 +0,0 @@ -From b0776d8c49ab4310fa056ce1033985996c5b9807 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Tue, 6 Feb 2018 16:22:34 -0500 -Subject: [PATCH] Bash-4.4 patch 19 - ---- - lib/readline/display.c | 4 +++- - patchlevel.h | 2 +- - 2 files changed, 4 insertions(+), 2 deletions(-) - -diff --git a/lib/readline/display.c b/lib/readline/display.c -index 41fb0531..2d2e768a 100644 ---- a/lib/readline/display.c -+++ b/lib/readline/display.c -@@ -771,7 +771,9 @@ rl_redisplay () - appear in the first and last lines of the prompt */ - wadjust = (newlines == 0) - ? prompt_invis_chars_first_line -- : ((newlines == prompt_lines_estimate) ? wrap_offset : prompt_invis_chars_first_line); -+ : ((newlines == prompt_lines_estimate) -+ ? (wrap_offset - prompt_invis_chars_first_line) -+ : 0); - - /* fix from Darin Johnson for prompt string with - invisible characters that is longer than the screen width. The -diff --git a/patchlevel.h b/patchlevel.h -index f0ee56e4..a711c495 100644 ---- 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 18 -+#define PATCHLEVEL 19 - - #endif /* _PATCHLEVEL_H_ */ --- -2.13.6 - diff --git a/system/base/bash/files/official/bash-4.4-patch-2.patch b/system/base/bash/files/official/bash-4.4-patch-2.patch deleted file mode 100644 index 373a92d7..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-2.patch +++ /dev/null @@ -1,59 +0,0 @@ -From 280bd77d8d3e7f7c90c9fa07de3d1e8f8e18ac29 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 14 Nov 2016 14:27:06 -0500 -Subject: [PATCH] Bash-4.4 patch 2 - ---- - patchlevel.h | 2 +- - subst.c | 9 ++++++++- - 2 files changed, 9 insertions(+), 2 deletions(-) - -diff --git a/patchlevel.h b/patchlevel.h -index 40db1a3..a988d85 100644 ---- 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 1 -+#define PATCHLEVEL 2 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/subst.c b/subst.c -index f1a4df1..4d498ef 100644 ---- a/subst.c -+++ b/subst.c -@@ -5931,6 +5931,7 @@ read_comsub (fd, quoted, rflag) - char *istring, buf[128], *bufp, *s; - int istring_index, istring_size, c, tflag, skip_ctlesc, skip_ctlnul; - ssize_t bufn; -+ int nullbyte; - - istring = (char *)NULL; - istring_index = istring_size = bufn = tflag = 0; -@@ -5938,6 +5939,8 @@ read_comsub (fd, quoted, rflag) - for (skip_ctlesc = skip_ctlnul = 0, s = ifs_value; s && *s; s++) - skip_ctlesc |= *s == CTLESC, skip_ctlnul |= *s == CTLNUL; - -+ nullbyte = 0; -+ - /* Read the output of the command through the pipe. This may need to be - changed to understand multibyte characters in the future. */ - while (1) -@@ -5956,7 +5959,11 @@ read_comsub (fd, quoted, rflag) - if (c == 0) - { - #if 1 -- internal_warning ("%s", _("command substitution: ignored null byte in input")); -+ if (nullbyte == 0) -+ { -+ internal_warning ("%s", _("command substitution: ignored null byte in input")); -+ nullbyte = 1; -+ } - #endif - continue; - } --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-3.patch b/system/base/bash/files/official/bash-4.4-patch-3.patch deleted file mode 100644 index 30b81cba..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-3.patch +++ /dev/null @@ -1,52 +0,0 @@ -From 4f59a8babc53a9f975078c4a003bdc8831c5ee22 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 14 Nov 2016 14:27:23 -0500 -Subject: [PATCH] Bash-4.4 patch 3 - ---- - lib/glob/sm_loop.c | 9 +++++++++ - patchlevel.h | 2 +- - 2 files changed, 10 insertions(+), 1 deletion(-) - -diff --git a/lib/glob/sm_loop.c b/lib/glob/sm_loop.c -index c3a2aa3..65179e2 100644 ---- a/lib/glob/sm_loop.c -+++ b/lib/glob/sm_loop.c -@@ -330,6 +330,12 @@ PARSE_COLLSYM (p, vp) - for (pc = 0; p[pc]; pc++) - if (p[pc] == L('.') && p[pc+1] == L(']')) - break; -+ if (p[pc] == 0) -+ { -+ if (vp) -+ *vp = INVALID; -+ return (p + pc); -+ } - val = COLLSYM (p, pc); - if (vp) - *vp = val; -@@ -483,6 +489,9 @@ BRACKMATCH (p, test, flags) - c = *p++; - c = FOLD (c); - -+ if (c == L('\0')) -+ return ((test == L('[')) ? savep : (CHAR *)0); -+ - if ((flags & FNM_PATHNAME) && c == L('/')) - /* [/] can never match when matching a pathname. */ - return (CHAR *)0; -diff --git a/patchlevel.h b/patchlevel.h -index a988d85..e7e960c 100644 ---- 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 2 -+#define PATCHLEVEL 3 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-4.patch b/system/base/bash/files/official/bash-4.4-patch-4.patch deleted file mode 100644 index f397be6b..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-4.patch +++ /dev/null @@ -1,81 +0,0 @@ -From 2965eca924466a48c5597ac5c6c86d470e718908 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 14 Nov 2016 14:27:35 -0500 -Subject: [PATCH] Bash-4.4 patch 4 - ---- - jobs.c | 15 +++++++++++++++ - jobs.h | 1 + - patchlevel.h | 2 +- - subst.c | 5 +---- - 4 files changed, 18 insertions(+), 5 deletions(-) - -diff --git a/jobs.c b/jobs.c -index cef3c79..fc96603 100644 ---- a/jobs.c -+++ b/jobs.c -@@ -453,6 +453,21 @@ cleanup_the_pipeline () - discard_pipeline (disposer); - } - -+void -+discard_last_procsub_child () -+{ -+ PROCESS *disposer; -+ sigset_t set, oset; -+ -+ BLOCK_CHILD (set, oset); -+ disposer = last_procsub_child; -+ last_procsub_child = (PROCESS *)NULL; -+ UNBLOCK_CHILD (oset); -+ -+ if (disposer) -+ discard_pipeline (disposer); -+} -+ - struct pipeline_saver * - alloc_pipeline_saver () - { -diff --git a/jobs.h b/jobs.h -index 4ba3513..6df0607 100644 ---- a/jobs.h -+++ b/jobs.h -@@ -190,6 +190,7 @@ extern JOB **jobs; - extern void making_children __P((void)); - extern void stop_making_children __P((void)); - extern void cleanup_the_pipeline __P((void)); -+extern void discard_last_procsub_child __P((void)); - extern void save_pipeline __P((int)); - extern PROCESS *restore_pipeline __P((int)); - extern void start_pipeline __P((void)); -diff --git a/patchlevel.h b/patchlevel.h -index e7e960c..c059f0b 100644 ---- 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 3 -+#define PATCHLEVEL 4 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/subst.c b/subst.c -index 4d498ef..298187d 100644 ---- a/subst.c -+++ b/subst.c -@@ -5808,10 +5808,7 @@ process_substitute (string, open_for_read_in_child) - { - #if defined (JOB_CONTROL) - if (last_procsub_child) -- { -- discard_pipeline (last_procsub_child); -- last_procsub_child = (PROCESS *)NULL; -- } -+ discard_last_procsub_child (); - last_procsub_child = restore_pipeline (0); - #endif - --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-5.patch b/system/base/bash/files/official/bash-4.4-patch-5.patch deleted file mode 100644 index 03b97616..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-5.patch +++ /dev/null @@ -1,42 +0,0 @@ -From f459cbd8be37b28be1dc90315e0ab51d7f211301 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Mon, 14 Nov 2016 14:27:55 -0500 -Subject: [PATCH] Bash-4.4 patch 5 - ---- - builtins/evalstring.c | 3 --- - patchlevel.h | 2 +- - 2 files changed, 1 insertion(+), 4 deletions(-) - -diff --git a/builtins/evalstring.c b/builtins/evalstring.c -index e221591..6dc756c 100644 ---- 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)); -diff --git a/patchlevel.h b/patchlevel.h -index c059f0b..1bc098b 100644 ---- 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_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-6.patch b/system/base/bash/files/official/bash-4.4-patch-6.patch deleted file mode 100644 index a6e3551e..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-6.patch +++ /dev/null @@ -1,50 +0,0 @@ -From 44bfefc553993613c0aff992bc4f3078d738ee1d Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 11:47:31 -0500 -Subject: [PATCH] Bash-4.4 patch 6 - ---- - builtins/pushd.def | 7 ++++++- - patchlevel.h | 2 +- - 2 files changed, 7 insertions(+), 2 deletions(-) - -diff --git a/builtins/pushd.def b/builtins/pushd.def -index 82653c4..6579e4c 100644 ---- a/builtins/pushd.def -+++ b/builtins/pushd.def -@@ -365,7 +365,7 @@ popd_builtin (list) - break; - } - -- if (which > directory_list_offset || (directory_list_offset == 0 && which == 0)) -+ if (which > directory_list_offset || (which < -directory_list_offset) || (directory_list_offset == 0 && which == 0)) - { - pushd_error (directory_list_offset, which_word ? which_word : ""); - return (EXECUTION_FAILURE); -@@ -387,6 +387,11 @@ popd_builtin (list) - remove that directory from the list and shift the remainder - of the list into place. */ - i = (direction == '+') ? directory_list_offset - which : which; -+ if (i < 0 || i > directory_list_offset) -+ { -+ pushd_error (directory_list_offset, which_word ? which_word : ""); -+ return (EXECUTION_FAILURE); -+ } - free (pushd_directory_list[i]); - directory_list_offset--; - -diff --git a/patchlevel.h b/patchlevel.h -index 1bc098b..14bff9f 100644 ---- 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 5 -+#define PATCHLEVEL 6 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-7.patch b/system/base/bash/files/official/bash-4.4-patch-7.patch deleted file mode 100644 index 2db3d824..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-7.patch +++ /dev/null @@ -1,114 +0,0 @@ -From 4f747edc625815f449048579f6e65869914dd715 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 11:47:55 -0500 -Subject: [PATCH] Bash-4.4 patch 7 - ---- - bashline.c | 22 ++++++++++++---------- - patchlevel.h | 2 +- - subst.c | 4 ++++ - 3 files changed, 17 insertions(+), 11 deletions(-) - -diff --git a/bashline.c b/bashline.c -index f4fe9f1..0275844 100644 ---- a/bashline.c -+++ b/bashline.c -@@ -142,7 +142,7 @@ static int executable_completion __P((const char *, int)); - static rl_icppfunc_t *save_directory_hook __P((void)); - static void restore_directory_hook __P((rl_icppfunc_t)); - --static int directory_exists __P((const char *)); -+static int directory_exists __P((const char *, int)); - - static void cleanup_expansion_error __P((void)); - static void maybe_make_readline_line __P((char *)); -@@ -3102,18 +3102,20 @@ restore_directory_hook (hookf) - rl_directory_rewrite_hook = hookf; - } - --/* Check whether not the (dequoted) version of DIRNAME, with any trailing slash -- removed, exists. */ -+/* Check whether not DIRNAME, with any trailing slash removed, exists. If -+ SHOULD_DEQUOTE is non-zero, we dequote the directory name first. */ - static int --directory_exists (dirname) -+directory_exists (dirname, should_dequote) - const char *dirname; -+ int should_dequote; - { - char *new_dirname; - int dirlen, r; - struct stat sb; - -- /* First, dequote the directory name */ -- new_dirname = bash_dequote_filename ((char *)dirname, rl_completion_quote_character); -+ /* We save the string and chop the trailing slash because stat/lstat behave -+ inconsistently if one is present. */ -+ new_dirname = should_dequote ? bash_dequote_filename ((char *)dirname, rl_completion_quote_character) : savestring (dirname); - dirlen = STRLEN (new_dirname); - if (new_dirname[dirlen - 1] == '/') - new_dirname[dirlen - 1] = '\0'; -@@ -3145,7 +3147,7 @@ bash_filename_stat_hook (dirname) - else if (t = mbschr (local_dirname, '`')) /* XXX */ - should_expand_dirname = '`'; - -- if (should_expand_dirname && directory_exists (local_dirname)) -+ if (should_expand_dirname && directory_exists (local_dirname, 0)) - should_expand_dirname = 0; - - if (should_expand_dirname) -@@ -3155,7 +3157,7 @@ bash_filename_stat_hook (dirname) - have to worry about restoring this setting. */ - global_nounset = unbound_vars_is_error; - unbound_vars_is_error = 0; -- wl = expand_prompt_string (new_dirname, 0, W_NOCOMSUB|W_COMPLETE); /* does the right thing */ -+ wl = expand_prompt_string (new_dirname, 0, W_NOCOMSUB|W_NOPROCSUB|W_COMPLETE); /* does the right thing */ - unbound_vars_is_error = global_nounset; - if (wl) - { -@@ -3244,13 +3246,13 @@ bash_directory_completion_hook (dirname) - should_expand_dirname = '`'; - } - -- if (should_expand_dirname && directory_exists (local_dirname)) -+ if (should_expand_dirname && directory_exists (local_dirname, 1)) - should_expand_dirname = 0; - - if (should_expand_dirname) - { - new_dirname = savestring (local_dirname); -- wl = expand_prompt_string (new_dirname, 0, W_NOCOMSUB|W_COMPLETE); /* does the right thing */ -+ wl = expand_prompt_string (new_dirname, 0, W_NOCOMSUB|W_NOPROCSUB|W_COMPLETE); /* does the right thing */ - if (wl) - { - *dirname = string_list (wl); -diff --git a/patchlevel.h b/patchlevel.h -index 14bff9f..deb9c5b 100644 ---- 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 6 -+#define PATCHLEVEL 7 - - #endif /* _PATCHLEVEL_H_ */ -diff --git a/subst.c b/subst.c -index 298187d..027a13e 100644 ---- a/subst.c -+++ b/subst.c -@@ -9458,6 +9458,10 @@ add_twochars: - tword->flags |= word->flags & (W_ASSIGNARG|W_ASSIGNRHS); /* affects $@ */ - if (word->flags & W_COMPLETE) - tword->flags |= W_COMPLETE; /* for command substitutions */ -+ if (word->flags & W_NOCOMSUB) -+ tword->flags |= W_NOCOMSUB; -+ if (word->flags & W_NOPROCSUB) -+ tword->flags |= W_NOPROCSUB; - - temp = (char *)NULL; - --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-8.patch b/system/base/bash/files/official/bash-4.4-patch-8.patch deleted file mode 100644 index fc435f95..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-8.patch +++ /dev/null @@ -1,71 +0,0 @@ -From b9f81c2977b82490cd4dc70b0bb292bfbf86bd2c Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 15:38:10 -0500 -Subject: [PATCH] Bash-4.4 patch 8 - ---- - expr.c | 15 +++++++++------ - patchlevel.h | 2 +- - 2 files changed, 10 insertions(+), 7 deletions(-) - -diff --git a/expr.c b/expr.c -index 1ddb693..172964a 100644 ---- a/expr.c -+++ b/expr.c -@@ -578,24 +578,23 @@ expcond () - rval = cval = explor (); - if (curtok == QUES) /* found conditional expr */ - { -- readtok (); -- if (curtok == 0 || curtok == COL) -- evalerror (_("expression expected")); - if (cval == 0) - { - set_noeval = 1; - noeval++; - } - -+ readtok (); -+ if (curtok == 0 || curtok == COL) -+ evalerror (_("expression expected")); -+ - val1 = EXP_HIGHEST (); - - if (set_noeval) - noeval--; - if (curtok != COL) - evalerror (_("`:' expected for conditional expression")); -- readtok (); -- if (curtok == 0) -- evalerror (_("expression expected")); -+ - set_noeval = 0; - if (cval) - { -@@ -603,7 +602,11 @@ expcond () - noeval++; - } - -+ readtok (); -+ if (curtok == 0) -+ evalerror (_("expression expected")); - val2 = expcond (); -+ - if (set_noeval) - noeval--; - rval = cval ? val1 : val2; -diff --git a/patchlevel.h b/patchlevel.h -index deb9c5b..16c8740 100644 ---- 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 7 -+#define PATCHLEVEL 8 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash-4.4-patch-9.patch b/system/base/bash/files/official/bash-4.4-patch-9.patch deleted file mode 100644 index b759e01e..00000000 --- a/system/base/bash/files/official/bash-4.4-patch-9.patch +++ /dev/null @@ -1,80 +0,0 @@ -From e59fb114e9c0436890d110cfdda4d794a63496e7 Mon Sep 17 00:00:00 2001 -From: Chet Ramey -Date: Fri, 20 Jan 2017 15:38:29 -0500 -Subject: [PATCH] Bash-4.4 patch 9 - ---- - lib/readline/history.c | 16 +++++++--------- - patchlevel.h | 2 +- - 2 files changed, 8 insertions(+), 10 deletions(-) - -diff --git a/lib/readline/history.c b/lib/readline/history.c -index 9ff25a7..129c57a 100644 ---- a/lib/readline/history.c -+++ b/lib/readline/history.c -@@ -279,6 +279,7 @@ add_history (string) - const char *string; - { - HIST_ENTRY *temp; -+ int new_length; - - if (history_stifled && (history_length == history_max_entries)) - { -@@ -295,13 +296,9 @@ add_history (string) - - /* Copy the rest of the entries, moving down one slot. Copy includes - trailing NULL. */ --#if 0 -- for (i = 0; i < history_length; i++) -- the_history[i] = the_history[i + 1]; --#else - memmove (the_history, the_history + 1, history_length * sizeof (HIST_ENTRY *)); --#endif - -+ new_length = history_length; - history_base++; - } - else -@@ -315,7 +312,7 @@ add_history (string) - else - history_size = DEFAULT_HISTORY_INITIAL_SIZE; - the_history = (HIST_ENTRY **)xmalloc (history_size * sizeof (HIST_ENTRY *)); -- history_length = 1; -+ new_length = 1; - } - else - { -@@ -325,14 +322,15 @@ add_history (string) - the_history = (HIST_ENTRY **) - xrealloc (the_history, history_size * sizeof (HIST_ENTRY *)); - } -- history_length++; -+ new_length = history_length + 1; - } - } - - temp = alloc_history_entry ((char *)string, hist_inittime ()); - -- the_history[history_length] = (HIST_ENTRY *)NULL; -- the_history[history_length - 1] = temp; -+ the_history[new_length] = (HIST_ENTRY *)NULL; -+ the_history[new_length - 1] = temp; -+ history_length = new_length; - } - - /* Change the time stamp of the most recent history entry to STRING. */ -diff --git a/patchlevel.h b/patchlevel.h -index 16c8740..02f1d60 100644 ---- 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 8 -+#define PATCHLEVEL 9 - - #endif /* _PATCHLEVEL_H_ */ --- -2.9.3 - diff --git a/system/base/bash/files/official/bash43-031.tar.gz b/system/base/bash/files/official/bash43-031.tar.gz deleted file mode 100644 index 33bee99029515aa4641fd3f66ff71806786fbe53..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1452 zcmV;d1ylMTiwFR#1q@XH1MOFBbJ|7_&R6&q>*SdR0Lvi>PVBl<{8H>VZaW?I zkPf7YkceKeNt*xOy*o*O?Zo*|PbM?o5hI=Mc5m<5XIIOZCZ5q&NLzdMXhI0-7zW^7 z>zah$i6+NFx|*qhrW+ldrC0aq^XUc@`+| zKZsN+72vWzI6s23!Nuz%7#*CQjxMUjO#il2tNTbAWyAtT6J}KmwOu`OfTQte}4G=l`!~4vu{U3tKy~U z+-kJ~KS>jH8fIz~Pg^v0Jb%GjUOEd}V^rb?YU#*Wh4fmpWQyc%@2Y%S9`FrIoYV?N3WY-YV8E!QJnk4=-oUt&4NftVM6%G7!34WNyk()Wp#Yft_^slxXFUXJ{<@AA;=ie(1q(L3tVtwM$^@N0@r@(RsB$y z5Pl_URR#=dbUqK3Vg>v&7q65#`MHh2V zrFT_Q2q?rPq^c+iY_8u$70h)@>sV%IW4(dv8=E40FnUca4`Rs8@u3d*q*MWZa@oWW z84S+P?c?8m8J_MBh81#y278rO0}w!m!8C}*G*}NrqjgL7WN>^iIye-n8sVyPwI5C) zjmlV-kfVW}4FiXx)8oQ`e#^ilj%Im~qRG9s0PsSc!+=f`?zISTlEz$}-J~%UyeSEk zs9fty0V)HpIyva3qM1N?mX4s4JD_t^@9M}v8CJV%8OApSN;iqo)J-i97Dz#wgE!#^ zYXTMbJ)HVf-NHG?qcJovTM(T+p>Te5FdW*KgAp_^Q1Nn4Vgn#X(1)6|1>10h14gDt*O>e-VTRgfrrr8K@`2u=1}9nHzDPxtjo1x3>#p_B?-A=PzrRgMQ+p&f5EaABdQh#&9UNvCD0g z7t(1FDBbLI5aeA_q`ECF}`ZlpCHL^9ij+F&#q{J|HT*KrDf#xY&`p=+nOr@JTK z$qg{g=W@)Q!BN0MVUC5aKjC5IbGaKBNb=xb9MBpq!o8Md63qLFz~SW6qS)EOT{|wS zz9d0in&NkgjuPbMtk| zm6=@B2DjujyP0F3U<><2z$L5ikb2CsJl6`C_-xAkn%rVje$a|)v%$`FQr?BBoENgk#EB9GJmlau^1aJzFc`B51e}*E}Wb- zO(0E>=fHz(m3uyD^0q$@+AhxXIe!vqEcnMpE%W~N^tKYVK5a!Opc9K| zmfrie)~D0NQnG4$cuCD0xd@me3 zv*E$z!4TR+_Czwxc(Cl%tbJs2U0LFq8|Cd$ebOHG>3jdteUc}6k|%kR4fziksP}gO G761VEm)0%- diff --git a/system/base/bash/files/official/bash43-032.tar.gz b/system/base/bash/files/official/bash43-032.tar.gz deleted file mode 100644 index a8f1d1f8b3193472911f5cd836fd467e8dacdf03..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 937 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 diff --git a/system/base/bash/files/official/bash43-038.tar.gz b/system/base/bash/files/official/bash43-038.tar.gz deleted file mode 100644 index 2005175e7eaafac3f4b84c829da466810a313405..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 871 zcmV-t1DO0DiwFQ>*q&7Y1MOC6Z`(!?%~$eQOc0`TiKHdV!|VmLe9e6kM^0souDyA8PYUu6Xx`LS3~% zS)LW82sCfUmAkBn#qPBmR|!d?l8B&!{-qlWSQ7Zqkc0iKwJ1dDi{_c%8E6({EfK4*mOL39cJDp^WrEaZV|abDu|yYKO8;f{c^#Tuq<<~>v1GYNj7OkvSOpV zg&#&+p@(G>>mE+33()HYH9FE0xxqz^390F}pi3eBBFf7sOS!79LR`m)9M=4BWc~LeW|7aIMSX_>bDQ$53~8gc~ty?;QiHV zzUV~eKYpP*2fVX5Qv8*6^^cjsp2<=)-qwwy04?8gX#7$nA}yb($A4t$9VuOp_^m}5 z)u;{3S^6KawBA@c7F!XM zu=b~+;blzgE!P@zd))D-eZNI_C*eMAY6b;^a>_WKU{BhoM`tEIFm#+{zereT1(X@A zqcms^ruK|!)`EUR)~A*4OW5K!5}u3Lu_8)01JX7E`}`^p>$=+J3uEE@>@2_>*A&1j xkp|HkusgR8?CtFKenV|?dT`#e<}~^9oc`@Ewi8Y`;e@{jzXSKyjdK7H001&2vD^Rv diff --git a/system/base/bash/files/official/bash43-039.tar.gz b/system/base/bash/files/official/bash43-039.tar.gz deleted file mode 100644 index 97e19e061a8bef700b095a638115b38b37d9886e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 851 zcmV-Z1FZZXiwFQ{*q&7Y1MO8?Z`(E$?yK}G&d`U%o+(i`J5jn~X=@+@f-Z2JzPhwb zTf}5iH)_)aDT^>3Q= z=Z@0JB!eU^@<~zTG^aq5bTXd20{VO@-IFtxX-wtD8Mpqf9@pkO@*WH9-~ST|f&e_d zJH0%Ei_`i0Gnh>;exJ?5JIOCkDGcA?(2yB#I5WHq@+b>0n5}B^+lMk(?gt9>+y>QJ zr7d5PjgWe1zR@U zgtlfDyseNsVFdEPsz)9pfO#zpv|6Eb3#zJ|Hhmm)%8U^kx#iM^OD7tO-i@njl>b)A{LqK7&K-?+BQ+i+xuICqX;} zsi0AE!}Wu94`c7a2h-d--3`YHp8xtLf^k-i#@Pb|co>cI;vRum!=dyuKe$D)5~fv# zFMPV@PPR|mt7F7LclZxcbWZm;Ad2==5O-71@EvcW+P4z>n35D*Ny~gv7L%`9>2W?a z%JD8CDTS1lG%3@sXXabgOUI*(_O2Ei$m0|!4008N)rvLx| diff --git a/system/base/bash/files/official/bash43-040.tar.gz b/system/base/bash/files/official/bash43-040.tar.gz deleted file mode 100644 index c06c31431d29e3af545c358e77f46177e99fae54..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 797 zcmV+&1LFK2iwFRGy(U-y1MO99Z__Xk=4e2-9{-nlVQN_)N!_;&h%bM;-r z?e~3f+@R+X6w*+ z!C4ObJUe58!-MzpX7pHAl3R2B=saM-1bF5(D_q^U9c+B(p zdX*Nrb-u{;;N$TqG!muC(6+NwDrqhA$|}UtW+G0~Gj1npmDw{4(v)qThtQtAl1tn_ z&$G0-DPf<>Sfr)GY@umR6U+dq1O_XOwS$!DGGFmr0cuilJ+jQEwa{W^nXTbtsuFlt)>EXU+ifJ& z>2$!dY@LtbUXa?#=eDe7QdzNqmHEV>ggSW2!k{1eeT!ZI^iENe5CT{Hbtj1H0v&`- zFATiz{5#*G<`DFEye>ZaP*1@*(gn22MaGsAw&3V#v^$wRfA(s8Flk@90DLy@Zax5O zFX3U+u?ROeWwVS&Ia_gP>1P+Vl@6tssh#f<#n`wc)T|nMz4<#r^87XD3V}mU1~CE zK1U9^hnpVY7x|MOVAVIU2qhj=&pe6Tm&Zld$u42cnHNI*4?vF0A3S5ynk& b!t3{!oc{KI&n<3oi@%GnIzu${01N;C!-S4} diff --git a/system/base/bash/files/official/bash43-041.tar.gz b/system/base/bash/files/official/bash43-041.tar.gz deleted file mode 100644 index e2a484ead689abdc7fa4a8e73fbb2579ec6ced54..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1163 zcmV;61a$i!iwFROy(U-y1MOD*Zrer-@4wbla466?o+aH$vK%XI&}Ipc0>&Do>HgUU zPnJ%W5LqYONeO~>ueBH0i;X<_Bk{7f+Yk%`!ocx~Uq|vsQl7^;4}6;i{Mn-sV=N2; zz;8Yt@w?xKf?(_c_eP=5$K2-(8285E_!+Rr3u#NOZeoR@+_t*SKBM;~d6x@pzW*oG z>-B)>_|5w>IDd2b-5Fe*p1-@ewAPYWyJT6%*fjQqC`GJA)C(NnI**$qx8I&bz4@l0 zP_JE}S}j#0QhR{%bTW-T(>NAqn$<7I#Mm% zSS5LJE!@0WmhK#lC~qNy(|!#iCk@ssU{EM$kz^T-PF2Fc+CbohBD+Td3ltZ~!nO$O@$!tGSVDby=0S z-KDjX3l*cqycC-VWCeu=Q4upeG+xVCW3ZJlrdCdVD&4uD0#eYm#0c-Z(T>%%6!g)8 z?kt)deyI)1uG!u`)@(2sfaADSXd8Rb379!k?oQIf(g!y8Y;OWQi2O+u_zqhW*lfg@ zW!pB~H$k)x&?wJH=GPqAB2p)u!ArHnO7#4Y5u?{AHPqqask{VtS3aUBW z@G4}nL+jhs<4vq*cOWyewJKR>MU~EyWjZr%pfC0QRzciV5C~=;|J{+N5|6!)cp1*N zJAe~e?KNF<)dUnFMrJYtRnDj^vw5502*JSZjEW5U8jeUzt~(~c$Mpe&%^Dic$oh3s0<0_T?>WNxxAn_Ta7OlVDRY^4AxJ3KjCn%`c;XhRTcDc>~qR}znhW`;$-t9|G9I5c&~kI^jAam zfFEKbrU(qRJQhXieFM)^f##z7r7=DI;dBZCBN4!J+$UHiL}j*>&dz3JONn(cZP)3e d#>BrI(|`TT?TMb~iJs`+(H}Kmj=}&C008o#HBtZo diff --git a/system/base/bash/files/official/bash43-042.tar.gz b/system/base/bash/files/official/bash43-042.tar.gz deleted file mode 100644 index 84af482f507cba06444e4e53d9f3980f3b0a7c5c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 747 zcmVX|o&q5i+Y0`CT@57Kt%Ew+e z&|)czz%3s4GUS;|MpIpZI3AggYW(jq zF!ZKDupSl#a@C=5Rn#t0(6tS$tkr6PVVFt|f*mDwln>4Nd}FFL61l|M0&6>9en4G= z&JD2Nl@@KI2Q12 z54xSt{o|9%(_VXL5l;En{!NO_*#o+xznQy}5vF(~ji!bS2S)U0jh69$uaQTYwTWNOLZi9M`^PjgYmHKV%~K;*1v7%5reMbp+~tDZ zyGyi8atO5vqrhlDt$=MkN+srP+O$!qsWs2P2pHw{FpUzNk!HTs6x3(IdL2Zkh#~>k z9A`SuK*$m&cf){|i5uy!V0Flm&YRa|xAUpf1;uLC71vV003uGa!~*P diff --git a/system/base/bash/files/official/bash43-043.tar.gz b/system/base/bash/files/official/bash43-043.tar.gz deleted file mode 100644 index 8e8e5f962f81158ea1e85bb3cf5f7c3e7fd30dd8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 934 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 diff --git a/system/base/bash/files/official/bash43-047.tar.gz b/system/base/bash/files/official/bash43-047.tar.gz deleted file mode 100644 index 8e6c33ff93ecb01f09f9247e64a31b8d5103eecc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1288 zcmV+j1^4sf+&j9ZA3B#cSFvMY}DBAd-&9Z#-MJhqLv_J!^;Z+bS7D&2Sm*hPV+9hq&0rB53Pz6O&VtWq%3s+UeAC+ zL35t)suj=*oS)DViYn!^xp6fYk`>*o60)QPg9wJ#u z$qfFewaTtZZ-ARO91g*8^hVo=I$MvjbX3zuFlXNJh#S~s+jhs`29fJVf$xx|0AiAm zu5H_J&3cY*;&1;7!J$RqB-B7N~UET*iWbV%GA5BO*TT zu1pdON(=aI_bDoHzZ)1L3Tg|gMAAGqmHf^B-ORwxHjy9;v?_K1v{Led#Zv7-tX_9@ zM(c?1%YKlEhB8**{70c}ES^t7EAU-+Sv=il5^N>V6TN7uKyMfZyin+4G46DxVcZuP z%kx;h4^+%IZ3Vq#CQ#@r)nIq+?xK&*P+O8azA$W!qWi zpT$#}ycap1kXWxAW21}Hs>Q}(6k=7G)fy}p?1q$UV8}kRLvq#mU^9&(=3!2W>lu)nDj)L|@w|@}Y9k=3_H=Q4QeO;Ax(-)U;-* z=c-P?uz*93oPHUo;8eJ)8B{kjpQ?Tkd~d~tI6k@{of*=FbG`>{{=q{`K%-Q z>B%Py-5o0oy-jWDN084lp74=;9*}&(ZGu(Zc7y)_`CuAj%w;1&9?9o_NO9J$Jj$bdh5QNkzu@u!7ytku&4TU# diff --git a/system/base/bash/files/official/bash43-048.tar.gz b/system/base/bash/files/official/bash43-048.tar.gz deleted file mode 100644 index d20244a52e7802d5b84006b5bf5196ca694b6db9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 853 zcmV-b1FHNViwFRuy(U-y1MOAYZsRr(-B;@?rr8COxRyl8^iA6qyW6Bl00V2pX#;}*FRps)%oJ%)wQ>`eE%4p_W?!YUkN3c5lN2*LvO(>&;84@q_@5k6#6wAbgL_E zMe46_lU`HDB%)+8osoA;HDzUjl=C3tK~o2{-34Sqi;@eM?mG+^MRA0Jh{kjlL@`Q< z3R#uEXNDEicQ;~PFsXuP(*5u#-_KX`q?cP;Ct;|hu_oA*O;G7g$TZL8R)o1NRJg{V zwu-QQ+K=L}FdH1{hz6~>tLjV`u4QeJN8)*x889fAl3Z4efyM|8oRuKUUj?^l+afyw zRR(XC7w7Z&$Hny$cvV^^OIdE<(`Tz07snne(>w31((q=nq+oMqF%?%$Dh!%=RTQnG zY1YO{+q5LmZY#8zTqxz~rgV9k0bNyg0Bt#NBb5U2xo%@^E}qYWAvMz$xq6*zo5#_( z$pt=RF@xZZbxa)Vbe|~jIvKzTt7~^jT7WFN^?(fXy0M6ID|J;CqO<|@Lsx1?lLG$s|20j=RAz9(8;uKL zSFKJ1(a02c9LTA&1FU74uJ*lsP|g6I-a0R#jM%xqWa*FP5<0mku@x%F+nL91=CgL@ zbdroF&+6oH5cSE>j|s#CRg%Qh2SM~Ngc6Sj!!Ko`s_Hl6b`*=rdJ$5B(GC};iCKY&d+~2p97tAy?ZTi{j#=!t9$F}VzpOA$LU@Z fFUo29bx!~Ff7t;C9B{w^{~Uh;&pW~l01f~EUht%% diff --git a/system/base/bash/files/official/bash50-001.patch b/system/base/bash/files/official/bash50-001.patch deleted file mode 100644 index 169317de..00000000 --- a/system/base/bash/files/official/bash50-001.patch +++ /dev/null @@ -1,166 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-001 - -Bug-Reported-by: axel@freakout.de -Bug-Reference-ID: <201901082050.x08KoShS006731@bongo.freakout.de> -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-01/msg00079.html - -Bug-Description: - -Under certain circumstances, the glob expansion code did not remove -backslashes escaping characters in directory names (or portions of a -pattern preceding a slash). - -Patch (apply with `patch -p0'): - -*** ../bash-5.0/bashline.c 2018-11-27 13:20:16.000000000 -0500 ---- bashline.c 2019-01-16 16:06:03.000000000 -0500 -*************** -*** 232,235 **** ---- 232,236 ---- - static int bash_possible_command_completions __P((int, int)); - -+ static int completion_glob_pattern __P((char *)); - static char *glob_complete_word __P((const char *, int)); - static int bash_glob_completion_internal __P((int)); -*************** -*** 1742,1746 **** - /* This could be a globbing pattern, so try to expand it using pathname - expansion. */ -! if (!matches && glob_pattern_p (text)) - { - matches = rl_completion_matches (text, glob_complete_word); ---- 1743,1747 ---- - /* This could be a globbing pattern, so try to expand it using pathname - expansion. */ -! if (!matches && completion_glob_pattern ((char *)text)) - { - matches = rl_completion_matches (text, glob_complete_word); -*************** -*** 1851,1855 **** - } - -! globpat = glob_pattern_p (hint_text); - - /* If this is an absolute program name, do not check it against ---- 1852,1856 ---- - } - -! globpat = completion_glob_pattern ((char *)hint_text); - - /* If this is an absolute program name, do not check it against -*************** -*** 3714,3717 **** ---- 3715,3773 ---- - } - -+ static int -+ completion_glob_pattern (string) -+ char *string; -+ { -+ register int c; -+ char *send; -+ int open; -+ -+ DECLARE_MBSTATE; -+ -+ open = 0; -+ send = string + strlen (string); -+ -+ while (c = *string++) -+ { -+ switch (c) -+ { -+ case '?': -+ case '*': -+ return (1); -+ -+ case '[': -+ open++; -+ continue; -+ -+ case ']': -+ if (open) -+ return (1); -+ continue; -+ -+ case '+': -+ case '@': -+ case '!': -+ if (*string == '(') /*)*/ -+ return (1); -+ continue; -+ -+ case '\\': -+ if (*string == 0) -+ return (0); -+ } -+ -+ /* Advance one fewer byte than an entire multibyte character to -+ account for the auto-increment in the loop above. */ -+ #ifdef HANDLE_MULTIBYTE -+ string--; -+ ADVANCE_CHAR_P (string, send - string); -+ string++; -+ #else -+ ADVANCE_CHAR_P (string, send - string); -+ #endif -+ } -+ return (0); -+ } -+ - static char *globtext; - static char *globorig; -*************** -*** 3878,3882 **** - } - -! if (t && glob_pattern_p (t) == 0) - rl_explicit_arg = 1; /* XXX - force glob_complete_word to append `*' */ - FREE (t); ---- 3934,3938 ---- - } - -! if (t && completion_glob_pattern (t) == 0) - rl_explicit_arg = 1; /* XXX - force glob_complete_word to append `*' */ - FREE (t); -*** ../bash-5.0/lib/glob/glob_loop.c 2018-12-31 13:35:15.000000000 -0500 ---- lib/glob/glob_loop.c 2019-01-09 09:44:36.000000000 -0500 -*************** -*** 55,59 **** - - case L('\\'): -- #if 0 - /* Don't let the pattern end in a backslash (GMATCH returns no match - if the pattern ends in a backslash anyway), but otherwise return 1, ---- 55,58 ---- -*************** -*** 61,69 **** - and it can be removed. */ - return (*p != L('\0')); -- #else -- /* The pattern may not end with a backslash. */ -- if (*p++ == L('\0')) -- return 0; -- #endif - } - ---- 60,63 ---- -*** ../bash-5.0/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 0 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 1 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-002.patch b/system/base/bash/files/official/bash50-002.patch deleted file mode 100644 index 3fc8272f..00000000 --- a/system/base/bash/files/official/bash50-002.patch +++ /dev/null @@ -1,113 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-002 - -Bug-Reported-by: Ante Peric -Bug-Reference-ID: -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-01/msg00095.html - -Bug-Description: - -When an alias value ends with an unquoted literal tab (not part of a quoted -string or comment), alias expansion cannot correctly detect the end of the -alias value after expanding it. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0/parser.h 2018-12-28 19:11:18.000000000 -0500 ---- parser.h 2019-01-11 15:13:03.000000000 -0500 -*************** -*** 48,51 **** ---- 48,52 ---- - #define PST_REDIRLIST 0x080000 /* parsing a list of redirections preceding a simple command name */ - #define PST_COMMENT 0x100000 /* parsing a shell comment; used by aliases */ -+ #define PST_ENDALIAS 0x200000 /* just finished expanding and consuming an alias */ - - /* Definition of the delimiter stack. Needed by parse.y and bashhist.c. */ -*** ../bash-5.0/parse.y 2019-01-02 13:57:34.000000000 -0500 ---- parse.y 2019-01-14 08:23:31.000000000 -0500 -*************** -*** 2558,2567 **** - pushed_string_list->flags != PSH_DPAREN && - (parser_state & PST_COMMENT) == 0 && - shell_input_line_index > 0 && -! shell_input_line[shell_input_line_index-1] != ' ' && - shell_input_line[shell_input_line_index-1] != '\n' && - shellmeta (shell_input_line[shell_input_line_index-1]) == 0 && - (current_delimiter (dstack) != '\'' && current_delimiter (dstack) != '"')) - { - return ' '; /* END_ALIAS */ - } ---- 2558,2569 ---- - pushed_string_list->flags != PSH_DPAREN && - (parser_state & PST_COMMENT) == 0 && -+ (parser_state & PST_ENDALIAS) == 0 && /* only once */ - shell_input_line_index > 0 && -! shellblank (shell_input_line[shell_input_line_index-1]) == 0 && - shell_input_line[shell_input_line_index-1] != '\n' && - shellmeta (shell_input_line[shell_input_line_index-1]) == 0 && - (current_delimiter (dstack) != '\'' && current_delimiter (dstack) != '"')) - { -+ parser_state |= PST_ENDALIAS; - return ' '; /* END_ALIAS */ - } -*************** -*** 2572,2575 **** ---- 2574,2578 ---- - if (uc == 0 && pushed_string_list && pushed_string_list->flags != PSH_SOURCE) - { -+ parser_state &= ~PST_ENDALIAS; - pop_string (); - uc = shell_input_line[shell_input_line_index]; -*** ../bash-5.0/y.tab.c 2019-01-02 13:57:43.000000000 -0500 ---- y.tab.c 2019-01-14 08:39:23.000000000 -0500 -*************** -*** 4874,4883 **** - pushed_string_list->flags != PSH_DPAREN && - (parser_state & PST_COMMENT) == 0 && - shell_input_line_index > 0 && -! shell_input_line[shell_input_line_index-1] != ' ' && - shell_input_line[shell_input_line_index-1] != '\n' && - shellmeta (shell_input_line[shell_input_line_index-1]) == 0 && - (current_delimiter (dstack) != '\'' && current_delimiter (dstack) != '"')) - { - return ' '; /* END_ALIAS */ - } ---- 4874,4885 ---- - pushed_string_list->flags != PSH_DPAREN && - (parser_state & PST_COMMENT) == 0 && -+ (parser_state & PST_ENDALIAS) == 0 && /* only once */ - shell_input_line_index > 0 && -! shellblank (shell_input_line[shell_input_line_index-1]) == 0 && - shell_input_line[shell_input_line_index-1] != '\n' && - shellmeta (shell_input_line[shell_input_line_index-1]) == 0 && - (current_delimiter (dstack) != '\'' && current_delimiter (dstack) != '"')) - { -+ parser_state |= PST_ENDALIAS; - return ' '; /* END_ALIAS */ - } -*************** -*** 4888,4891 **** ---- 4890,4894 ---- - if (uc == 0 && pushed_string_list && pushed_string_list->flags != PSH_SOURCE) - { -+ parser_state &= ~PST_ENDALIAS; - pop_string (); - uc = shell_input_line[shell_input_line_index]; -*** ../bash-5.0/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 1 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 2 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-003.patch b/system/base/bash/files/official/bash50-003.patch deleted file mode 100644 index f7e5677e..00000000 --- a/system/base/bash/files/official/bash50-003.patch +++ /dev/null @@ -1,239 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-003 - -Bug-Reported-by: Andrew Church -Bug-Reference-ID: <5c534aa2.04371@msgid.achurch.org> -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-01/msg00276.html - -Bug-Description: - -There are several incompatibilities in how bash-5.0 processes pathname -expansion (globbing) of filename arguments that have backslashes in the -directory portion. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/lib/glob/glob_loop.c 2019-01-16 16:13:21.000000000 -0500 ---- lib/glob/glob_loop.c 2019-02-01 09:45:11.000000000 -0500 -*************** -*** 27,34 **** - register const GCHAR *p; - register GCHAR c; -! int bopen; - - p = pattern; -! bopen = 0; - - while ((c = *p++) != L('\0')) ---- 27,34 ---- - register const GCHAR *p; - register GCHAR c; -! int bopen, bsquote; - - p = pattern; -! bopen = bsquote = 0; - - while ((c = *p++) != L('\0')) -*************** -*** 56,66 **** - case L('\\'): - /* Don't let the pattern end in a backslash (GMATCH returns no match -! if the pattern ends in a backslash anyway), but otherwise return 1, -! since the matching engine uses backslash as an escape character -! and it can be removed. */ -! return (*p != L('\0')); - } - -! return 0; - } - ---- 56,75 ---- - case L('\\'): - /* Don't let the pattern end in a backslash (GMATCH returns no match -! if the pattern ends in a backslash anyway), but otherwise note that -! we have seen this, since the matching engine uses backslash as an -! escape character and it can be removed. We return 2 later if we -! have seen only backslash-escaped characters, so interested callers -! know they can shortcut and just dequote the pathname. */ -! if (*p != L('\0')) -! { -! p++; -! bsquote = 1; -! continue; -! } -! else /* (*p == L('\0')) */ -! return 0; - } - -! return bsquote ? 2 : 0; - } - -*** ../bash-5.0-patched/lib/glob/glob.h 2013-10-28 14:46:12.000000000 -0400 ---- lib/glob/glob.h 2019-03-07 11:06:47.000000000 -0500 -*************** -*** 31,34 **** ---- 31,35 ---- - #define GX_ADDCURDIR 0x200 /* internal -- add passed directory name */ - #define GX_GLOBSTAR 0x400 /* turn on special handling of ** */ -+ #define GX_RECURSE 0x800 /* internal -- glob_filename called recursively */ - - extern int glob_pattern_p __P((const char *)); -*** ../bash-5.0-patched/lib/glob/glob.c 2018-09-20 10:53:23.000000000 -0400 ---- lib/glob/glob.c 2019-03-07 14:23:43.000000000 -0500 -*************** -*** 1062,1066 **** - unsigned int directory_len; - int free_dirname; /* flag */ -! int dflags; - - result = (char **) malloc (sizeof (char *)); ---- 1078,1082 ---- - unsigned int directory_len; - int free_dirname; /* flag */ -! int dflags, hasglob; - - result = (char **) malloc (sizeof (char *)); -*************** -*** 1111,1117 **** - } - - /* If directory_name contains globbing characters, then we -! have to expand the previous levels. Just recurse. */ -! if (directory_len > 0 && glob_pattern_p (directory_name)) - { - char **directories, *d, *p; ---- 1127,1136 ---- - } - -+ hasglob = 0; - /* If directory_name contains globbing characters, then we -! have to expand the previous levels. Just recurse. -! If glob_pattern_p returns != [0,1] we have a pattern that has backslash -! quotes but no unquoted glob pattern characters. We dequote it below. */ -! if (directory_len > 0 && (hasglob = glob_pattern_p (directory_name)) == 1) - { - char **directories, *d, *p; -*************** -*** 1176,1180 **** - d[directory_len - 1] = '\0'; - -! directories = glob_filename (d, dflags); - - if (free_dirname) ---- 1195,1199 ---- - d[directory_len - 1] = '\0'; - -! directories = glob_filename (d, dflags|GX_RECURSE); - - if (free_dirname) -*************** -*** 1333,1336 **** ---- 1352,1369 ---- - return (NULL); - } -+ /* If we have a directory name with quoted characters, and we are -+ being called recursively to glob the directory portion of a pathname, -+ we need to dequote the directory name before returning it so the -+ caller can read the directory */ -+ if (directory_len > 0 && hasglob == 2 && (flags & GX_RECURSE) != 0) -+ { -+ dequote_pathname (directory_name); -+ directory_len = strlen (directory_name); -+ } -+ -+ /* We could check whether or not the dequoted directory_name is a -+ directory and return it here, returning the original directory_name -+ if not, but we don't do that yet. I'm not sure it matters. */ -+ - /* Handle GX_MARKDIRS here. */ - result[0] = (char *) malloc (directory_len + 1); -*** ../bash-5.0-patched/pathexp.c 2018-04-29 17:44:48.000000000 -0400 ---- pathexp.c 2019-01-31 20:19:41.000000000 -0500 -*************** -*** 66,74 **** - register int c; - char *send; -! int open; - - DECLARE_MBSTATE; - -! open = 0; - send = string + strlen (string); - ---- 66,74 ---- - register int c; - char *send; -! int open, bsquote; - - DECLARE_MBSTATE; - -! open = bsquote = 0; - send = string + strlen (string); - -*************** -*** 101,105 **** - globbing. */ - case '\\': -! return (*string != 0); - - case CTLESC: ---- 101,112 ---- - globbing. */ - case '\\': -! if (*string != '\0' && *string != '/') -! { -! bsquote = 1; -! string++; -! continue; -! } -! else if (*string == 0) -! return (0); - - case CTLESC: -*************** -*** 118,122 **** - #endif - } -! return (0); - } - ---- 125,130 ---- - #endif - } -! -! return (bsquote ? 2 : 0); - } - -*** ../bash-5.0-patched/bashline.c 2019-01-16 16:13:21.000000000 -0500 ---- bashline.c 2019-02-22 09:29:08.000000000 -0500 -*************** -*** 3753,3757 **** - - case '\\': -! if (*string == 0) - return (0); - } ---- 3766,3770 ---- - - case '\\': -! if (*string++ == 0) - return (0); - } -*** ../bash-5.0/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 2 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 3 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-004.patch b/system/base/bash/files/official/bash50-004.patch deleted file mode 100644 index fe3c764b..00000000 --- a/system/base/bash/files/official/bash50-004.patch +++ /dev/null @@ -1,53 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-004 - -Bug-Reported-by: Daniel Kahn Gillmor -Bug-Reference-ID: <87lg0g8aiw.fsf@fifthhorseman.net> -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-04/msg00076.html - -Bug-Description: - -In bash-5.0, the `wait' builtin without arguments waits for all children of the -shell. This includes children it `inherited' at shell invocation time. This -patch modifies the behavior to not wait for these inherited children, some -of which might be long-lived. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/jobs.c 2018-12-06 11:44:34.000000000 -0500 ---- jobs.c 2019-04-12 15:15:10.000000000 -0400 -*************** -*** 2489,2496 **** - wait_procsubs (); - reap_procsubs (); -! #if 1 - /* We don't want to wait indefinitely if we have stopped children. */ -- /* XXX - should add a loop that goes through the list of process -- substitutions and waits for each proc in turn before this code. */ - if (any_stopped == 0) - { ---- 2490,2495 ---- - wait_procsubs (); - reap_procsubs (); -! #if 0 - /* We don't want to wait indefinitely if we have stopped children. */ - if (any_stopped == 0) - { -*** ../bash-5.0/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 3 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 4 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-005.patch b/system/base/bash/files/official/bash50-005.patch deleted file mode 100644 index 9b1cd75b..00000000 --- a/system/base/bash/files/official/bash50-005.patch +++ /dev/null @@ -1,110 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-005 - -Bug-Reported-by: Brad Spencer -Bug-Reference-ID: <1b993ff2-ce4f-662a-6be4-393457362e47@blackberry.com> -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-01/msg00250.html - -Bug-Description: - -In certain cases, bash optimizes out a fork() call too early and prevents -traps from running. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/command.h 2018-07-20 21:16:31.000000000 -0400 ---- command.h 2019-02-20 11:09:36.000000000 -0500 -*************** -*** 187,190 **** ---- 188,192 ---- - #define CMD_LASTPIPE 0x2000 - #define CMD_STDPATH 0x4000 /* use standard path for command lookup */ -+ #define CMD_TRY_OPTIMIZING 0x8000 /* try to optimize this simple command */ - - /* What a command looks like. */ -*** ../bash-5.0-patched/builtins/evalstring.c 2018-12-26 11:19:21.000000000 -0500 ---- builtins/evalstring.c 2019-01-29 14:15:19.000000000 -0500 -*************** -*** 101,104 **** ---- 101,113 ---- - } - -+ int -+ can_optimize_connection (command) -+ COMMAND *command; -+ { -+ return (*bash_input.location.string == '\0' && -+ (command->value.Connection->connector == AND_AND || command->value.Connection->connector == OR_OR || command->value.Connection->connector == ';') && -+ command->value.Connection->second->type == cm_simple); -+ } -+ - void - optimize_fork (command) -*************** -*** 106,110 **** - { - if (command->type == cm_connection && -! (command->value.Connection->connector == AND_AND || command->value.Connection->connector == OR_OR) && - should_suppress_fork (command->value.Connection->second)) - { ---- 115,120 ---- - { - if (command->type == cm_connection && -! (command->value.Connection->connector == AND_AND || command->value.Connection->connector == OR_OR || command->value.Connection->connector == ';') && -! (command->value.Connection->second->flags & CMD_TRY_OPTIMIZING) && - should_suppress_fork (command->value.Connection->second)) - { -*************** -*** 413,418 **** - command->value.Simple->flags |= CMD_NO_FORK; - } -! else if (command->type == cm_connection) -! optimize_fork (command); - #endif /* ONESHOT */ - ---- 423,438 ---- - command->value.Simple->flags |= CMD_NO_FORK; - } -! -! /* Can't optimize forks out here execept for simple commands. -! This knows that the parser sets up commands as left-side heavy -! (&& and || are left-associative) and after the single parse, -! if we are at the end of the command string, the last in a -! series of connection commands is -! command->value.Connection->second. */ -! else if (command->type == cm_connection && can_optimize_connection (command)) -! { -! command->value.Connection->second->flags |= CMD_TRY_OPTIMIZING; -! command->value.Connection->second->value.Simple->flags |= CMD_TRY_OPTIMIZING; -! } - #endif /* ONESHOT */ - -*** ../bash-5.0-patched/execute_cmd.c 2018-12-05 09:05:14.000000000 -0500 ---- execute_cmd.c 2019-01-25 15:59:00.000000000 -0500 -*************** -*** 2768,2771 **** ---- 2768,2773 ---- - (exec_result != EXECUTION_SUCCESS))) - { -+ optimize_fork (command); -+ - second = command->value.Connection->second; - if (ignore_return && second) -*** ../bash-5.0/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 4 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 5 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-006.patch b/system/base/bash/files/official/bash50-006.patch deleted file mode 100644 index 2ad1cd20..00000000 --- a/system/base/bash/files/official/bash50-006.patch +++ /dev/null @@ -1,47 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-006 - -Bug-Reported-by: Tomas Mozes -Bug-Reference-ID: -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-03/msg00037.html - -Bug-Description: - -Bash-5.0 did not build successfully if SYSLOG_HISTORY was defined without -also defining SYSLOG_SHOPT. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/builtins/shopt.def 2018-10-05 14:49:02.000000000 -0400 ---- builtins/shopt.def 2019-01-23 09:55:22.000000000 -0500 -*************** -*** 123,127 **** - #endif - -! #if defined (SYSLOG_HISTORY) && defined (SYSLOG_SHOPT) - extern int syslog_history; - #endif ---- 123,127 ---- - #endif - -! #if defined (SYSLOG_HISTORY) - extern int syslog_history; - #endif -*** ../bash-5.0/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 5 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 6 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-007.patch b/system/base/bash/files/official/bash50-007.patch deleted file mode 100644 index b9eb4150..00000000 --- a/system/base/bash/files/official/bash50-007.patch +++ /dev/null @@ -1,62 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-007 - -Bug-Reported-by: Grisha Levit -Bug-Reference-ID: -Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2019-02/msg00067.html - -Bug-Description: - -Running `exec' when job control was disabled, even temporarily, but after it -had been initialized, could leave the terminal in the wrong process group for -the executed process. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/jobs.c 2018-12-06 11:44:34.000000000 -0500 ---- jobs.c 2019-04-12 15:15:10.000000000 -0400 -*************** -*** 4838,4850 **** - { - if (job_control) -! { -! terminate_stopped_jobs (); - -! if (original_pgrp >= 0) -! give_terminal_to (original_pgrp, 1); -! } - -! if (original_pgrp >= 0) -! setpgid (0, original_pgrp); - } - ---- 4838,4848 ---- - { - if (job_control) -! terminate_stopped_jobs (); - -! if (original_pgrp >= 0 && terminal_pgrp != original_pgrp) -! give_terminal_to (original_pgrp, 1); - -! if (original_pgrp >= 0 && setpgid (0, original_pgrp) == 0) -! shell_pgrp = original_pgrp; - } - -*** ../bash-5.0/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 6 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 7 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-008.patch b/system/base/bash/files/official/bash50-008.patch deleted file mode 100644 index b09d6b33..00000000 --- a/system/base/bash/files/official/bash50-008.patch +++ /dev/null @@ -1,68 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-008 - -Bug-Reported-by: Michael Albinus -Bug-Reference-ID: <87bm36k3kz.fsf@gmx.de> -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-02/msg00111.html - -Bug-Description: - -When HISTSIZE is set to 0, history expansion can leave the history length -set to an incorrect value, leading to subsequent attempts to access invalid -memory. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/bashhist.c 2018-07-05 22:41:14.000000000 -0400 ---- bashhist.c 2019-02-20 16:20:04.000000000 -0500 -*************** -*** 561,573 **** - if (!history_expansion_inhibited && history_expansion && history_expansion_p (line)) - { - /* If we are expanding the second or later line of a multi-line - command, decrease history_length so references to history expansions - in these lines refer to the previous history entry and not the - current command. */ - if (history_length > 0 && command_oriented_history && current_command_first_line_saved && current_command_line_count > 1) - history_length--; - expanded = history_expand (line, &history_value); - if (history_length >= 0 && command_oriented_history && current_command_first_line_saved && current_command_line_count > 1) -! history_length++; - - if (expanded) ---- 561,576 ---- - if (!history_expansion_inhibited && history_expansion && history_expansion_p (line)) - { -+ int old_len; -+ - /* If we are expanding the second or later line of a multi-line - command, decrease history_length so references to history expansions - in these lines refer to the previous history entry and not the - current command. */ -+ old_len = history_length; - if (history_length > 0 && command_oriented_history && current_command_first_line_saved && current_command_line_count > 1) - history_length--; - expanded = history_expand (line, &history_value); - if (history_length >= 0 && command_oriented_history && current_command_first_line_saved && current_command_line_count > 1) -! history_length = old_len; - - if (expanded) - -*** ../bash-5.0/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 7 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 8 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-009.patch b/system/base/bash/files/official/bash50-009.patch deleted file mode 100644 index aef4ce7b..00000000 --- a/system/base/bash/files/official/bash50-009.patch +++ /dev/null @@ -1,42 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-009 - -Bug-Reported-by: chet.ramey@case.edu -Bug-Reference-ID: -Bug-Reference-URL: - -Bug-Description: - -The history file reading code doesn't close the file descriptor open to -the history file when it encounters a zero-length file. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/lib/readline/histfile.c 2018-06-11 09:14:52.000000000 -0400 ---- lib/readline/histfile.c 2019-05-16 15:55:57.000000000 -0400 -*************** -*** 306,309 **** ---- 312,316 ---- - { - free (input); -+ close (file); - return 0; /* don't waste time if we don't have to */ - } -*** ../bash-5.0/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 8 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 9 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-010.patch b/system/base/bash/files/official/bash50-010.patch deleted file mode 100644 index bac7aa92..00000000 --- a/system/base/bash/files/official/bash50-010.patch +++ /dev/null @@ -1,172 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-010 - -Bug-Reported-by: Thorsten Glaser -Bug-Reference-ID: <156622962831.19438.16374961114836556294.reportbug@tglase.lan.tarent.de> -Bug-Reference-URL: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=935115 - -Bug-Description: - -Bash-5.0 changed the way assignment statements preceding special builtins -and shell functions were handled in posix mode. They automatically created -or modified global variables instead of modifying existing local variables -as in bash-4.4. - -The bash-4.4 posix-mode semantics were buggy, and resulted in creating -local variables where they were not intended and modifying global variables -and local variables simultaneously. - -The bash-5.0 changes were intended to fix this issue, but did not preserve -enough backwards compatibility. The posix standard also changed what it -required in these cases, so bash-5.0 is not bound by the strict conformance -requirements that existed in previous issues of the standard. - -This patch modifies the bash-5.0 posix mode behavior in an effort to restore -some backwards compatibility and rationalize the behavior in the presence of -local variables. It - -1. Changes the assignment semantics to be more similar to standalone assignment - statements: assignments preceding a function call or special builtin while - executing in a shell function will modify the value of a local variable - with the same name for the duration of the function's execution; - -2. Changes assignments preceding shell function calls or special builtins - from within a shell function to no longer create or modify global variables - in the presence of a local variable with the same name; - -3. Assignment statements preceding a shell function call or special builtin - at the global scope continue to modify the (global) calling environment, - but are unaffected by assignments preceding function calls or special - builtins within a function, as described in item 2. This is also similar - to the behavior of a standalone assignment statement. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/variables.c 2018-12-18 11:07:21.000000000 -0500 ---- variables.c 2019-08-22 10:53:44.000000000 -0400 -*************** -*** 4461,4467 **** - - /* Take a variable from an assignment statement preceding a posix special -! builtin (including `return') and create a global variable from it. This -! is called from merge_temporary_env, which is only called when in posix -! mode. */ - static void - push_posix_temp_var (data) ---- 4461,4467 ---- - - /* Take a variable from an assignment statement preceding a posix special -! builtin (including `return') and create a variable from it as if a -! standalone assignment statement had been performed. This is called from -! merge_temporary_env, which is only called when in posix mode. */ - static void - push_posix_temp_var (data) -*************** -*** 4473,4486 **** - var = (SHELL_VAR *)data; - -! binding_table = global_variables->table; -! if (binding_table == 0) -! binding_table = global_variables->table = hash_create (VARIABLES_HASH_BUCKETS); -! -! v = bind_variable_internal (var->name, value_cell (var), binding_table, 0, ASS_FORCE|ASS_NOLONGJMP); - - /* global variables are no longer temporary and don't need propagating. */ -! var->attributes &= ~(att_tempvar|att_propagate); - if (v) -! v->attributes |= var->attributes; - - if (find_special_var (var->name) >= 0) ---- 4473,4497 ---- - var = (SHELL_VAR *)data; - -! /* Just like do_assignment_internal(). This makes assignments preceding -! special builtins act like standalone assignment statements when in -! posix mode, satisfying the posix requirement that this affect the -! "current execution environment." */ -! v = bind_variable (var->name, value_cell (var), ASS_FORCE|ASS_NOLONGJMP); -! -! /* If this modifies an existing local variable, v->context will be non-zero. -! If it comes back with v->context == 0, we bound at the global context. -! Set binding_table appropriately. It doesn't matter whether it's correct -! if the variable is local, only that it's not global_variables->table */ -! binding_table = v->context ? shell_variables->table : global_variables->table; - - /* global variables are no longer temporary and don't need propagating. */ -! if (binding_table == global_variables->table) -! var->attributes &= ~(att_tempvar|att_propagate); -! - if (v) -! { -! v->attributes |= var->attributes; -! v->attributes &= ~att_tempvar; /* not a temp var now */ -! } - - if (find_special_var (var->name) >= 0) -*************** -*** 4576,4587 **** - { - int i; - - tempvar_list = strvec_create (HASH_ENTRIES (temporary_env) + 1); - tempvar_list[tvlist_ind = 0] = 0; -! -! hash_flush (temporary_env, pushf); -! hash_dispose (temporary_env); - temporary_env = (HASH_TABLE *)NULL; - - tempvar_list[tvlist_ind] = 0; - ---- 4587,4601 ---- - { - int i; -+ HASH_TABLE *disposer; - - tempvar_list = strvec_create (HASH_ENTRIES (temporary_env) + 1); - tempvar_list[tvlist_ind = 0] = 0; -! -! disposer = temporary_env; - temporary_env = (HASH_TABLE *)NULL; - -+ hash_flush (disposer, pushf); -+ hash_dispose (disposer); -+ - tempvar_list[tvlist_ind] = 0; - -*** ../bash-5.0-patched/tests/varenv.right 2018-12-17 15:39:48.000000000 -0500 ---- tests/varenv.right 2019-08-22 16:05:25.000000000 -0400 -*************** -*** 147,153 **** - outside: declare -- var="one" - inside: declare -x var="value" -! outside: declare -x var="value" -! inside: declare -- var="local" -! outside: declare -x var="global" - foo= environment foo= - foo=foo environment foo=foo ---- 147,153 ---- - outside: declare -- var="one" - inside: declare -x var="value" -! outside: declare -- var="outside" -! inside: declare -x var="global" -! outside: declare -- var="outside" - foo= environment foo= - foo=foo environment foo=foo -*** ../bash-5.0/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 9 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 10 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-011.patch b/system/base/bash/files/official/bash50-011.patch deleted file mode 100644 index a9ae690e..00000000 --- a/system/base/bash/files/official/bash50-011.patch +++ /dev/null @@ -1,59 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-011 - -Bug-Reported-by: Matt Whitlock -Bug-Reference-ID: -Bug-Reference-URL: https://savannah.gnu.org/support/?109671 - -Bug-Description: - -The conditional command did not perform appropriate quoted null character -removal on its arguments, causing syntax errors and attempts to stat -invalid pathnames. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/subst.c 2018-12-22 17:43:37.000000000 -0500 ---- subst.c 2019-04-14 13:25:41.000000000 -0400 -*************** -*** 3626,3630 **** - SPECIAL is 2, this is an rhs argument for the =~ operator, and should - be quoted appropriately for regcomp/regexec. The caller is responsible -! for removing the backslashes if the unquoted word is needed later. */ - char * - cond_expand_word (w, special) ---- 3642,3648 ---- - SPECIAL is 2, this is an rhs argument for the =~ operator, and should - be quoted appropriately for regcomp/regexec. The caller is responsible -! for removing the backslashes if the unquoted word is needed later. In -! any case, since we don't perform word splitting, we need to do quoted -! null character removal. */ - char * - cond_expand_word (w, special) -*************** -*** 3647,3650 **** ---- 3665,3670 ---- - if (special == 0) /* LHS */ - { -+ if (l->word) -+ word_list_remove_quoted_nulls (l); - dequote_list (l); - r = string_list (l); -*** ../bash-5.0/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 10 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 11 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-012.patch b/system/base/bash/files/official/bash50-012.patch deleted file mode 100644 index 7470e766..00000000 --- a/system/base/bash/files/official/bash50-012.patch +++ /dev/null @@ -1,64 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-012 - -Bug-Reported-by: lessbug@qq.com -Bug-Reference-ID: -Bug-Reference-URL: - -Bug-Description: - -When using previous-history to go back beyond the beginning of the history list, -it's possible to move to an incorrect partial line. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/lib/readline/misc.c 2017-07-07 17:30:12.000000000 -0400 ---- lib/readline/misc.c 2019-05-16 11:43:46.000000000 -0400 -*************** -*** 577,580 **** ---- 590,594 ---- - { - HIST_ENTRY *old_temp, *temp; -+ int had_saved_line; - - if (count < 0) -*************** -*** 589,592 **** ---- 603,607 ---- - - /* If we don't have a line saved, then save this one. */ -+ had_saved_line = _rl_saved_line_for_history != 0; - rl_maybe_save_line (); - -*************** -*** 612,616 **** - if (temp == 0) - { -! rl_maybe_unsave_line (); - rl_ding (); - } ---- 627,632 ---- - if (temp == 0) - { -! if (had_saved_line == 0) -! _rl_free_saved_history_line (); - rl_ding (); - } -*** ../bash-5.0/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 11 - - #endif /* _PATCHLEVEL_H_ */ ---- 26,30 ---- - looks for to find the patch level (for the sccs version string). */ - -! #define PATCHLEVEL 12 - - #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash50-013.patch b/system/base/bash/files/official/bash50-013.patch deleted file mode 100644 index e44fdb50..00000000 --- a/system/base/bash/files/official/bash50-013.patch +++ /dev/null @@ -1,73 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-013 - -Bug-Reported-by: HIROSE Masaaki -Bug-Reference-ID: -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-05/msg00038.html - -Bug-Description: - -Reading history entries with timestamps can result in history entries joined -by linefeeds. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/lib/readline/histfile.c 2018-06-11 09:14:52.000000000 -0400 ---- lib/readline/histfile.c 2019-05-16 15:55:57.000000000 -0400 -*************** -*** 370,376 **** - - has_timestamps = HIST_TIMESTAMP_START (buffer); -! history_multiline_entries += has_timestamps && history_write_timestamps; - - /* Skip lines until we are at FROM. */ - for (line_start = line_end = buffer; line_end < bufend && current_line < from; line_end++) - if (*line_end == '\n') ---- 370,378 ---- - - has_timestamps = HIST_TIMESTAMP_START (buffer); -! history_multiline_entries += has_timestamps && history_write_timestamps; - - /* Skip lines until we are at FROM. */ -+ if (has_timestamps) -+ last_ts = buffer; - for (line_start = line_end = buffer; line_end < bufend && current_line < from; line_end++) - if (*line_end == '\n') -*************** -*** 381,385 **** ---- 383,398 ---- - if (HIST_TIMESTAMP_START(p) == 0) - current_line++; -+ else -+ last_ts = p; - line_start = p; -+ /* If we are at the last line (current_line == from) but we have -+ timestamps (has_timestamps), then line_start points to the -+ text of the last command, and we need to skip to its end. */ -+ if (current_line >= from && has_timestamps) -+ { -+ for (line_end = p; line_end < bufend && *line_end != '\n'; line_end++) -+ ; -+ line_start = (*line_end == '\n') ? line_end + 1 : line_end; -+ } - } - - -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash50-014.patch b/system/base/bash/files/official/bash50-014.patch deleted file mode 100644 index 6cb49aae..00000000 --- a/system/base/bash/files/official/bash50-014.patch +++ /dev/null @@ -1,52 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-014 - -Bug-Reported-by: Johannes Hielscher -Bug-Reference-ID: <20190208205048.77c25a83@hordevm> -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-02/msg00032.html - -Bug-Description: - -If the current line is empty, using the emacs C-xC-e binding to enter the -editor will edit the previous command instead of the current (empty) one. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/bashline.c 2019-01-16 16:13:21.000000000 -0500 ---- bashline.c 2019-02-11 11:18:57.000000000 -0500 -*************** -*** 962,970 **** - finished with the command, so we should not ignore the last command */ - using_history (); -! if (rl_line_buffer[0]) -! { -! current_command_line_count++; /* for rl_newline above */ -! bash_add_history (rl_line_buffer); -! } - current_command_line_count = 0; /* for dummy history entry */ - bash_add_history (""); ---- 965,970 ---- - finished with the command, so we should not ignore the last command */ - using_history (); -! current_command_line_count++; /* for rl_newline above */ -! bash_add_history (rl_line_buffer); - current_command_line_count = 0; /* for dummy history entry */ - bash_add_history (""); -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash50-015.patch b/system/base/bash/files/official/bash50-015.patch deleted file mode 100644 index ff6e5e69..00000000 --- a/system/base/bash/files/official/bash50-015.patch +++ /dev/null @@ -1,78 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-015 - -Bug-Reported-by: Yu Kou -Bug-Reference-ID: -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-05/msg00032.html - -Bug-Description: - -If alias expansion is enabled when processing the command argument to the -`-c' option, an alias is defined in that command, and the command ends with -the invocation of that alias, the shell's command parser can prematurely -terminate before the entire command is executed. - -Patch (apply with `patch -p0'): - -*** ../bash-20190426/builtins/evalstring.c 2019-01-29 14:15:19.000000000 -0500 ---- builtins/evalstring.c 2019-05-15 14:19:36.000000000 -0400 -*************** -*** 92,95 **** ---- 92,96 ---- - running_trap == 0 && - *bash_input.location.string == '\0' && -+ parser_expanding_alias () == 0 && - command->type == cm_simple && - signal_is_trapped (EXIT_TRAP) == 0 && -*************** -*** 106,109 **** ---- 107,111 ---- - { - return (*bash_input.location.string == '\0' && -+ parser_expanding_alias () == 0 && - (command->value.Connection->connector == AND_AND || command->value.Connection->connector == OR_OR || command->value.Connection->connector == ';') && - command->value.Connection->second->type == cm_simple); -*************** -*** 291,295 **** - with_input_from_string (string, from_file); - clear_shell_input_line (); -! while (*(bash_input.location.string)) - { - command = (COMMAND *)NULL; ---- 293,297 ---- - with_input_from_string (string, from_file); - clear_shell_input_line (); -! while (*(bash_input.location.string) || parser_expanding_alias ()) - { - command = (COMMAND *)NULL; -*************** -*** 546,550 **** - - with_input_from_string (string, from_file); -! while (*(bash_input.location.string)) - { - command = (COMMAND *)NULL; ---- 548,552 ---- - - with_input_from_string (string, from_file); -! while (*(bash_input.location.string)) /* XXX - parser_expanding_alias () ? */ - { - command = (COMMAND *)NULL; -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash50-016.patch b/system/base/bash/files/official/bash50-016.patch deleted file mode 100644 index 87f232d7..00000000 --- a/system/base/bash/files/official/bash50-016.patch +++ /dev/null @@ -1,58 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-016 - -Bug-Reported-by: sunnycemetery@gmail.com -Bug-Reference-ID: <20190316041534.GB22884@midnight> -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-03/msg00070.html - -Bug-Description: - -Bash waits too long to reap /dev/fd process substitutions used as redirections -with loops and group commands, which can lead to file descriptor exhaustion. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/execute_cmd.c 2019-04-19 15:46:36.000000000 -0400 ---- execute_cmd.c 2019-07-01 16:45:49.000000000 -0400 -*************** -*** 1104,1107 **** ---- 1085,1104 ---- - discard_unwind_frame ("internal_fifos"); - } -+ # if defined (HAVE_DEV_FD) -+ /* Reap process substitutions at the end of loops */ -+ switch (command->type) -+ { -+ case cm_while: -+ case cm_until: -+ case cm_for: -+ case cm_group: -+ # if defined (ARITH_FOR_COMMAND) -+ case cm_arith_for: -+ # endif -+ reap_procsubs (); -+ default: -+ break; -+ } -+ # endif /* HAVE_DEV_FD */ - #endif - - -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash50-017.patch b/system/base/bash/files/official/bash50-017.patch deleted file mode 100644 index adfcb6a8..00000000 --- a/system/base/bash/files/official/bash50-017.patch +++ /dev/null @@ -1,289 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-017 - -Bug-Reported-by: Valentin Lab -Bug-Reference-ID: -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2020-03/msg00062.html - -Bug-Description: - -There were cases where patch 16 reaped process substitution file descriptors -(or FIFOs) and processes to early. This is a better fix for the problem that -bash50-016 attempted to solve. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0-patched/subst.c 2019-08-29 11:16:49.000000000 -0400 ---- subst.c 2020-04-02 16:24:19.000000000 -0400 -*************** -*** 5337,5341 **** - } - -! char * - copy_fifo_list (sizep) - int *sizep; ---- 5337,5341 ---- - } - -! void * - copy_fifo_list (sizep) - int *sizep; -*************** -*** 5343,5347 **** - if (sizep) - *sizep = 0; -! return (char *)NULL; - } - ---- 5343,5347 ---- - if (sizep) - *sizep = 0; -! return (void *)NULL; - } - -*************** -*** 5409,5414 **** - if (fifo_list[i].file) - { -! fifo_list[j].file = fifo_list[i].file; -! fifo_list[j].proc = fifo_list[i].proc; - j++; - } ---- 5409,5419 ---- - if (fifo_list[i].file) - { -! if (i != j) -! { -! fifo_list[j].file = fifo_list[i].file; -! fifo_list[j].proc = fifo_list[i].proc; -! fifo_list[i].file = (char *)NULL; -! fifo_list[i].proc = 0; -! } - j++; - } -*************** -*** 5426,5433 **** - void - close_new_fifos (list, lsize) -! char *list; - int lsize; - { - int i; - - if (list == 0) ---- 5431,5439 ---- - void - close_new_fifos (list, lsize) -! void *list; - int lsize; - { - int i; -+ char *plist; - - if (list == 0) -*************** -*** 5437,5442 **** - } - -! for (i = 0; i < lsize; i++) -! if (list[i] == 0 && i < fifo_list_size && fifo_list[i].proc != -1) - unlink_fifo (i); - ---- 5443,5448 ---- - } - -! for (plist = (char *)list, i = 0; i < lsize; i++) -! if (plist[i] == 0 && i < fifo_list_size && fifo_list[i].proc != -1) - unlink_fifo (i); - -*************** -*** 5560,5568 **** - } - -! char * - copy_fifo_list (sizep) - int *sizep; - { -! char *ret; - - if (nfds == 0 || totfds == 0) ---- 5566,5574 ---- - } - -! void * - copy_fifo_list (sizep) - int *sizep; - { -! void *ret; - - if (nfds == 0 || totfds == 0) -*************** -*** 5570,5579 **** - if (sizep) - *sizep = 0; -! return (char *)NULL; - } - - if (sizep) - *sizep = totfds; -! ret = (char *)xmalloc (totfds * sizeof (pid_t)); - return (memcpy (ret, dev_fd_list, totfds * sizeof (pid_t))); - } ---- 5576,5585 ---- - if (sizep) - *sizep = 0; -! return (void *)NULL; - } - - if (sizep) - *sizep = totfds; -! ret = xmalloc (totfds * sizeof (pid_t)); - return (memcpy (ret, dev_fd_list, totfds * sizeof (pid_t))); - } -*************** -*** 5648,5655 **** - void - close_new_fifos (list, lsize) -! char *list; - int lsize; - { - int i; - - if (list == 0) ---- 5654,5662 ---- - void - close_new_fifos (list, lsize) -! void *list; - int lsize; - { - int i; -+ pid_t *plist; - - if (list == 0) -*************** -*** 5659,5664 **** - } - -! for (i = 0; i < lsize; i++) -! if (list[i] == 0 && i < totfds && dev_fd_list[i]) - unlink_fifo (i); - ---- 5666,5671 ---- - } - -! for (plist = (pid_t *)list, i = 0; i < lsize; i++) -! if (plist[i] == 0 && i < totfds && dev_fd_list[i]) - unlink_fifo (i); - -*** ../bash-5.0-patched/subst.h 2018-10-21 18:46:09.000000000 -0400 ---- subst.h 2020-04-02 16:29:28.000000000 -0400 -*************** -*** 274,280 **** - extern void unlink_fifo __P((int)); - -! extern char *copy_fifo_list __P((int *)); -! extern void unlink_new_fifos __P((char *, int)); -! extern void close_new_fifos __P((char *, int)); - - extern void clear_fifo_list __P((void)); ---- 274,279 ---- - extern void unlink_fifo __P((int)); - -! extern void *copy_fifo_list __P((int *)); -! extern void close_new_fifos __P((void *, int)); - - extern void clear_fifo_list __P((void)); -*** ../bash-5.0-patched/execute_cmd.c 2020-02-06 20:16:48.000000000 -0500 ---- execute_cmd.c 2020-04-02 17:00:10.000000000 -0400 -*************** -*** 565,569 **** - #if defined (PROCESS_SUBSTITUTION) - volatile int ofifo, nfifo, osize, saved_fifo; -! volatile char *ofifo_list; - #endif - ---- 565,569 ---- - #if defined (PROCESS_SUBSTITUTION) - volatile int ofifo, nfifo, osize, saved_fifo; -! volatile void *ofifo_list; - #endif - -*************** -*** 751,760 **** - # endif - -! if (variable_context != 0) /* XXX - also if sourcelevel != 0? */ - { - ofifo = num_fifos (); - ofifo_list = copy_fifo_list ((int *)&osize); - begin_unwind_frame ("internal_fifos"); -! add_unwind_protect (xfree, ofifo_list); - saved_fifo = 1; - } ---- 751,762 ---- - # endif - -! /* XXX - also if sourcelevel != 0? */ -! if (variable_context != 0) - { - ofifo = num_fifos (); - ofifo_list = copy_fifo_list ((int *)&osize); - begin_unwind_frame ("internal_fifos"); -! if (ofifo_list) -! add_unwind_protect (xfree, ofifo_list); - saved_fifo = 1; - } -*************** -*** 1100,1123 **** - nfifo = num_fifos (); - if (nfifo > ofifo) -! close_new_fifos ((char *)ofifo_list, osize); - free ((void *)ofifo_list); - discard_unwind_frame ("internal_fifos"); - } -- # if defined (HAVE_DEV_FD) -- /* Reap process substitutions at the end of loops */ -- switch (command->type) -- { -- case cm_while: -- case cm_until: -- case cm_for: -- case cm_group: -- # if defined (ARITH_FOR_COMMAND) -- case cm_arith_for: -- # endif -- reap_procsubs (); -- default: -- break; -- } -- # endif /* HAVE_DEV_FD */ - #endif - ---- 1102,1109 ---- - nfifo = num_fifos (); - if (nfifo > ofifo) -! close_new_fifos ((void *)ofifo_list, osize); - free ((void *)ofifo_list); - discard_unwind_frame ("internal_fifos"); - } - #endif - - -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash50-018.patch b/system/base/bash/files/official/bash50-018.patch deleted file mode 100644 index 6f1b1c7c..00000000 --- a/system/base/bash/files/official/bash50-018.patch +++ /dev/null @@ -1,45 +0,0 @@ - BASH PATCH REPORT - ================= - -Bash-Release: 5.0 -Patch-ID: bash50-018 - -Bug-Reported-by: oguzismailuysal@gmail.com -Bug-Reference-ID: -Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2019-10/msg00098.html - -Bug-Description: - -In certain cases, bash does not perform quoted null removal on patterns -that are used as part of word expansions such as ${parameter##pattern}, so -empty patterns are treated as non-empty. - -Patch (apply with `patch -p0'): - -*** ../bash-5.0.17/subst.c 2020-04-02 17:14:58.000000000 -0400 ---- subst.c 2020-07-09 15:28:19.000000000 -0400 -*************** -*** 5113,5116 **** ---- 5113,5118 ---- - (int *)NULL, (int *)NULL) - : (WORD_LIST *)0; -+ if (l) -+ word_list_remove_quoted_nulls (l); - pat = string_list (l); - dispose_words (l); - -*** ../bash-5.0/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_ */ diff --git a/system/base/bash/files/official/bash51-001.patch b/system/base/bash/files/official/bash51-001.patch new file mode 100644 index 00000000..6f29981d --- /dev/null +++ b/system/base/bash/files/official/bash51-001.patch @@ -0,0 +1,80 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 5.1 +Patch-ID: bash51-001 + +Bug-Reported-by: Fazal Majid +Bug-Reference-ID: +Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2020-12/msg00000.html + +Bug-Description: + +There is a missing dependency on a constructed file, which can cause highly +parellel builds to fail. + +Patch (apply with `patch -p0'): + +*** ../bash-5.1-patched/Makefile.in 2020-12-04 09:51:19.000000000 -0500 +--- Makefile.in 2020-12-16 11:28:36.000000000 -0500 +*************** +*** 1316,1319 **** +--- 1316,1320 ---- + bashline.o: pcomplete.h ${BASHINCDIR}/chartypes.h input.h + bashline.o: ${BASHINCDIR}/shmbutil.h ${BASHINCDIR}/shmbchar.h ++ bashline.o: ${DEFDIR}/builtext.h + bracecomp.o: config.h bashansi.h ${BASHINCDIR}/ansi_stdlib.h + bracecomp.o: shell.h syntax.h config.h bashjmp.h ${BASHINCDIR}/posixjmp.h +*************** +*** 1436,1439 **** +--- 1437,1441 ---- + builtins/evalstring.o: jobs.h builtins.h flags.h input.h execute_cmd.h + builtins/evalstring.o: bashhist.h $(DEFSRC)/common.h pathnames.h ++ builtins/evalstring.o: ${DEFDIR}/builtext.h + builtins/getopt.o: config.h ${BASHINCDIR}/memalloc.h + builtins/getopt.o: shell.h syntax.h bashjmp.h command.h general.h xmalloc.h error.h + +*** ../bash-5.1-patched/builtins/Makefile.in 2019-07-25 08:03:45.000000000 -0400 +--- builtins/Makefile.in 2020-12-16 11:29:29.000000000 -0500 +*************** +*** 362,366 **** + evalstring.o: $(topdir)/flags.h $(topdir)/input.h $(topdir)/execute_cmd.h + evalstring.o: $(topdir)/bashhist.h $(srcdir)/common.h +! evalstring.o: $(topdir)/trap.h $(topdir)/redir.h ../pathnames.h + #evalstring.o: $(topdir)/y.tab.h + getopt.o: ../config.h $(BASHINCDIR)/memalloc.h +--- 362,366 ---- + evalstring.o: $(topdir)/flags.h $(topdir)/input.h $(topdir)/execute_cmd.h + evalstring.o: $(topdir)/bashhist.h $(srcdir)/common.h +! evalstring.o: $(topdir)/trap.h $(topdir)/redir.h ../pathnames.h ./builtext.h + #evalstring.o: $(topdir)/y.tab.h + getopt.o: ../config.h $(BASHINCDIR)/memalloc.h + +*** ../bash-5.1/patchlevel.h 2020-06-22 14:51:03.000000000 -0400 +--- patchlevel.h 2020-10-01 11:01:28.000000000 -0400 +*************** +*** 1,5 **** + /* patchlevel.h -- current bash patch level */ + +! /* Copyright (C) 2001-2016 Free Software Foundation, Inc. + + This file is part of GNU Bash, the Bourne Again SHell. +--- 1,5 ---- + /* patchlevel.h -- current bash patch level */ + +! /* Copyright (C) 2001-2020 Free Software Foundation, Inc. + + This file is part of GNU Bash, the Bourne Again SHell. +*************** +*** 26,30 **** + looks for to find the patch level (for the sccs version string). */ + +! #define PATCHLEVEL 0 + + #endif /* _PATCHLEVEL_H_ */ +--- 26,30 ---- + looks for to find the patch level (for the sccs version string). */ + +! #define PATCHLEVEL 1 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash51-002.patch b/system/base/bash/files/official/bash51-002.patch new file mode 100644 index 00000000..8c991649 --- /dev/null +++ b/system/base/bash/files/official/bash51-002.patch @@ -0,0 +1,57 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 5.1 +Patch-ID: bash51-002 + +Bug-Reported-by: oguzismailuysal@gmail.com +Bug-Reference-ID: +Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2020-12/msg00037.html + +Bug-Description: + +If there are no jobs, and the `-n' and `-p' options are both supplied to +`wait', bash can assign a value to the variable name specified with `-p' +instead of leaving it unset. + +Patch (apply with `patch -p0'): + +*** ../bash-5.1-patched/builtins/wait.def 2020-04-09 15:13:57.000000000 -0400 +--- builtins/wait.def 2020-12-11 09:46:49.000000000 -0500 +*************** +*** 214,222 **** + + status = wait_for_any_job (wflags, &pstat); +- if (status < 0) +- status = 127; +- + if (vname && status >= 0) + bind_var_to_int (vname, pstat.pid); + if (list) + unset_waitlist (); +--- 214,222 ---- + + status = wait_for_any_job (wflags, &pstat); + if (vname && status >= 0) + bind_var_to_int (vname, pstat.pid); ++ ++ if (status < 0) ++ status = 127; + if (list) + unset_waitlist (); + +*** ../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 1 + + #endif /* _PATCHLEVEL_H_ */ +--- 26,30 ---- + looks for to find the patch level (for the sccs version string). */ + +! #define PATCHLEVEL 2 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash51-003.patch b/system/base/bash/files/official/bash51-003.patch new file mode 100644 index 00000000..68e5dce6 --- /dev/null +++ b/system/base/bash/files/official/bash51-003.patch @@ -0,0 +1,53 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 5.1 +Patch-ID: bash51-003 + +Bug-Reported-by: oguzismailuysal@gmail.com +Bug-Reference-ID: +Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2020-12/msg00050.html + +Bug-Description: + +Bash does not put a command substitution process that is started to perform an +expansion in a child process into the right process group where it can receive +keyboard-generated signals. + +Patch (apply with `patch -p0'): + +*** ../bash-5.1-patched/subst.c 2020-11-16 10:33:15.000000000 -0500 +--- subst.c 2020-12-12 13:50:11.000000000 -0500 +*************** +*** 6357,6362 **** + #if defined (JOB_CONTROL) + old_pipeline_pgrp = pipeline_pgrp; +! /* Don't reset the pipeline pgrp if we're already a subshell in a pipeline. */ +! if ((subshell_environment & SUBSHELL_PIPE) == 0) + pipeline_pgrp = shell_pgrp; + cleanup_the_pipeline (); +--- 6357,6364 ---- + #if defined (JOB_CONTROL) + old_pipeline_pgrp = pipeline_pgrp; +! /* Don't reset the pipeline pgrp if we're already a subshell in a pipeline or +! we've already forked to run a disk command (and are expanding redirections, +! for example). */ +! if ((subshell_environment & (SUBSHELL_FORK|SUBSHELL_PIPE)) == 0) + pipeline_pgrp = shell_pgrp; + cleanup_the_pipeline (); + +*** ../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 2 + + #endif /* _PATCHLEVEL_H_ */ +--- 26,30 ---- + looks for to find the patch level (for the sccs version string). */ + +! #define PATCHLEVEL 3 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/files/official/bash51-004.patch b/system/base/bash/files/official/bash51-004.patch new file mode 100644 index 00000000..39a6c647 --- /dev/null +++ b/system/base/bash/files/official/bash51-004.patch @@ -0,0 +1,126 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 5.1 +Patch-ID: bash51-004 + +Bug-Reported-by: oguzismailuysal@gmail.com +Bug-Reference-ID: +Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-bash/2020-12/msg00039.html + +Bug-Description: + +If a key-value compound array assignment to an associative array is supplied +as an assignment statement argument to the `declare' command that declares the +array, the assignment doesn't perform the correct word expansions. + +This patch makes key-value assignment and subscript assignment perform the +same expansions when they're supplied as an argument to `declare'. + +Patch (apply with `patch -p0'): + +*** ../bash-5.1-patched/arrayfunc.c 2020-10-09 11:38:58.000000000 -0400 +--- arrayfunc.c 2020-12-11 15:12:22.000000000 -0500 +*************** +*** 598,601 **** +--- 598,622 ---- + } + } ++ ++ /* Return non-zero if L appears to be a key-value pair associative array ++ compound assignment. */ ++ int ++ kvpair_assignment_p (l) ++ WORD_LIST *l; ++ { ++ return (l && (l->word->flags & W_ASSIGNMENT) == 0 && l->word->word[0] != '['); /*]*/ ++ } ++ ++ char * ++ expand_and_quote_kvpair_word (w) ++ char *w; ++ { ++ char *t, *r; ++ ++ t = w ? expand_assignment_string_to_string (w, 0) : 0; ++ r = sh_single_quote (t ? t : ""); ++ free (t); ++ return r; ++ } + #endif + +*************** +*** 641,645 **** + + #if ASSOC_KVPAIR_ASSIGNMENT +! if (assoc_p (var) && nlist && (nlist->word->flags & W_ASSIGNMENT) == 0 && nlist->word->word[0] != '[') /*]*/ + { + iflags = flags & ~ASS_APPEND; +--- 662,666 ---- + + #if ASSOC_KVPAIR_ASSIGNMENT +! if (assoc_p (var) && kvpair_assignment_p (nlist)) + { + iflags = flags & ~ASS_APPEND; +*** ../bash-5.1-patched/arrayfunc.h 2020-04-29 17:24:15.000000000 -0400 +--- arrayfunc.h 2020-12-11 14:23:50.000000000 -0500 +*************** +*** 68,71 **** +--- 68,74 ---- + extern void quote_compound_array_list PARAMS((WORD_LIST *, int)); + ++ extern int kvpair_assignment_p PARAMS((WORD_LIST *)); ++ extern char *expand_and_quote_kvpair_word PARAMS((char *)); ++ + extern int unbind_array_element PARAMS((SHELL_VAR *, char *, int)); + extern int skipsubscript PARAMS((const char *, int, int)); +*** ../bash-5.1-patched/subst.c 2020-11-16 10:33:15.000000000 -0500 +--- subst.c 2020-12-11 15:11:10.000000000 -0500 +*************** +*** 11605,11608 **** +--- 11605,11609 ---- + WORD_LIST *l, *nl; + char *t; ++ int kvpair; + + if (flags == 0) +*************** +*** 11619,11622 **** +--- 11620,11627 ---- + /* Associative array */ + l = parse_string_to_word_list (value, 1, "array assign"); ++ #if ASSOC_KVPAIR_ASSIGNMENT ++ kvpair = kvpair_assignment_p (l); ++ #endif ++ + /* For associative arrays, with their arbitrary subscripts, we have to + expand and quote in one step so we don't have to search for the +*************** +*** 11624,11627 **** +--- 11629,11638 ---- + for (nl = l; nl; nl = nl->next) + { ++ #if ASSOC_KVPAIR_ASSIGNMENT ++ if (kvpair) ++ /* keys and values undergo the same set of expansions */ ++ t = expand_and_quote_kvpair_word (nl->word->word); ++ else ++ #endif + if ((nl->word->flags & W_ASSIGNMENT) == 0) + t = sh_single_quote (nl->word->word ? nl->word->word : ""); + +*** ../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 3 + + #endif /* _PATCHLEVEL_H_ */ +--- 26,30 ---- + looks for to find the patch level (for the sccs version string). */ + +! #define PATCHLEVEL 4 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/system/base/bash/pspec.xml b/system/base/bash/pspec.xml index 5759da11..8317c134 100755 --- a/system/base/bash/pspec.xml +++ b/system/base/bash/pspec.xml @@ -12,31 +12,17 @@ app:console

The standard GNU Bourne again shell Bash is the GNU Project's Bourne Again SHell, a complete implementation of the IEEE POSIX and Open Group shell specification with interactive command line editing, csh-like features such as history substitution. - mirrors://gnu/bash/bash-5.0.tar.gz + mirrors://gnu/bash/bash-5.1.tar.gz ncurses-devel - official/bash50-001.patch - official/bash50-002.patch - official/bash50-003.patch - official/bash50-004.patch - official/bash50-005.patch - official/bash50-006.patch - official/bash50-007.patch - official/bash50-008.patch - official/bash50-009.patch - official/bash50-010.patch - official/bash50-011.patch - official/bash50-012.patch - official/bash50-013.patch - official/bash50-014.patch - official/bash50-015.patch - official/bash50-016.patch - official/bash50-017.patch - official/bash50-018.patch + official/bash51-001.patch + official/bash51-002.patch + official/bash51-003.patch + official/bash51-004.patch fedora/bash-2.02-security.patch @@ -64,7 +50,7 @@ fedora/bash-4.2-size_type.patch fedora/bash-4.3-man-ulimit.patch - fedora/bash-4.3-memleak-lc_all.patch + fedora/bash-4.4-no-loadable-builtins.patch @@ -91,6 +77,13 @@ + + 2021-03-01 + 5.1.4 + Version bump. + Idris Kalp + idriskalp@gmail.com + 2020-12-09 5.0.18