summaryrefslogtreecommitdiffstats
path: root/debian/patches/bash51-014.diff
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 06:17:26 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 06:17:26 +0000
commit3abb3f4db4372683dde9d2565d27d807ffdd5ac4 (patch)
tree83da6f31e160b887fcf21342ac42b2ea21a457c0 /debian/patches/bash51-014.diff
parentAdding upstream version 5.1. (diff)
downloadbash-3abb3f4db4372683dde9d2565d27d807ffdd5ac4.tar.xz
bash-3abb3f4db4372683dde9d2565d27d807ffdd5ac4.zip
Adding debian version 5.1-2+deb11u1.debian/5.1-2+deb11u1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches/bash51-014.diff')
-rw-r--r--debian/patches/bash51-014.diff26
1 files changed, 26 insertions, 0 deletions
diff --git a/debian/patches/bash51-014.diff b/debian/patches/bash51-014.diff
new file mode 100644
index 0000000..47dfe35
--- /dev/null
+++ b/debian/patches/bash51-014.diff
@@ -0,0 +1,26 @@
+ BASH PATCH REPORT
+ =================
+
+Bash-Release: 5.1
+Patch-ID: bash51-014
+
+Bug-Reported-by: platon7pronko@gmail.com
+Bug-Reference-ID:
+Bug-Reference-URL: https://savannah.gnu.org/patch/?10035
+
+Bug-Description:
+
+Bash may produce corrupted input if a multibyte character spans a 512-byte
+boundary while reading the output of a command substitution.
+
+--- a/subst.c
++++ b/subst.c
+@@ -6242,7 +6242,7 @@ read_comsub (fd, quoted, flags, rflag)
+ /* read a multibyte character from buf */
+ /* punt on the hard case for now */
+ memset (&ps, '\0', sizeof (mbstate_t));
+- mblen = mbrtowc (&wc, bufp-1, bufn+1, &ps);
++ mblen = mbrtowc (&wc, bufp-1, bufn, &ps);
+ if (MB_INVALIDCH (mblen) || mblen == 0 || mblen == 1)
+ istring[istring_index++] = c;
+ else