pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/shells/bash



Module Name:    pkgsrc
Committed By:   rillig
Date:           Tue Mar 17 17:09:48 UTC 2020

Modified Files:
        pkgsrc/shells/bash: distinfo
Added Files:
        pkgsrc/shells/bash/patches: patch-bashline.c patch-lib_malloc_malloc.c
            patch-subst.c

Log Message:
shells/bash: fix array subscript with char


To generate a diff of this commit:
cvs rdiff -u -r1.57 -r1.58 pkgsrc/shells/bash/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/shells/bash/patches/patch-bashline.c \
    pkgsrc/shells/bash/patches/patch-lib_malloc_malloc.c \
    pkgsrc/shells/bash/patches/patch-subst.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/shells/bash/distinfo
diff -u pkgsrc/shells/bash/distinfo:1.57 pkgsrc/shells/bash/distinfo:1.58
--- pkgsrc/shells/bash/distinfo:1.57    Tue Feb 11 11:45:25 2020
+++ pkgsrc/shells/bash/distinfo Tue Mar 17 17:09:48 2020
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.57 2020/02/11 11:45:25 kre Exp $
+$NetBSD: distinfo,v 1.58 2020/03/17 17:09:48 rillig Exp $
 
 SHA1 (bash-5.0.tar.gz) = d116b469b9e6ea5264a74661d3a4c797da7f997b
 RMD160 (bash-5.0.tar.gz) = a081428a896d617855499376b670eca3433a27c1
@@ -71,10 +71,13 @@ Size (bash50-016) = 1534 bytes
 SHA1 (patch-af) = e26e3209902247263884cfebc11a2f7e43245062
 SHA1 (patch-ag) = cd3b151e3bb045d2bb609c0a03d7d3df2c871f47
 SHA1 (patch-aj) = 2e4c15afd9b50d44967ee8e1f85bdc908c0eeeb0
+SHA1 (patch-bashline.c) = 812de2510f3eca741bfee38bad14bcaa8091681e
 SHA1 (patch-builtins_ulimit.def) = 1390069344607204eb3abbd6ddeb148ff590c55e
 SHA1 (patch-configure) = c4e1ab53a1ee85f3e6121047f0aca8ceb85e6e5d
 SHA1 (patch-examples_loadables_fdflags.c) = 92a63c8f4c94ccf9cf782e934a0806930d172654
 SHA1 (patch-examples_loadables_push.c) = 57a3c7de9ea0a75c373db678d9500954bcf40ff4
+SHA1 (patch-lib_malloc_malloc.c) = 83e93dfa6b65de77878425f8dff51ecb53085323
 SHA1 (patch-shell.c) = daa07914d4c318cd72463f80344f4f7c364809cd
+SHA1 (patch-subst.c) = b0dccd5dc96c19eba1dd160e4def0f9291ce06e1
 SHA1 (patch-support_shobj-conf) = 8750c104549ea8a4a722bd21a684a9fe13e05fe5
 SHA1 (patch-variables.c) = 8d91272602aba348dc158d8fb5948edd90d96646

Added files:

Index: pkgsrc/shells/bash/patches/patch-bashline.c
diff -u /dev/null pkgsrc/shells/bash/patches/patch-bashline.c:1.1
--- /dev/null   Tue Mar 17 17:09:48 2020
+++ pkgsrc/shells/bash/patches/patch-bashline.c Tue Mar 17 17:09:48 2020
@@ -0,0 +1,15 @@
+$NetBSD: patch-bashline.c,v 1.1 2020/03/17 17:09:48 rillig Exp $
+
+Fix array subscript with char index.
+
+--- bashline.c.orig    2020-03-17 16:57:19.058552795 +0000
++++ bashline.c
+@@ -4050,7 +4050,7 @@ set_filename_bstab (string)
+ 
+   memset (filename_bstab, 0, sizeof (filename_bstab));
+   for (s = string; s && *s; s++)
+-    filename_bstab[*s] = 1;
++    filename_bstab[(unsigned char) *s] = 1;
+ }
+ 
+ /* Quote a filename using double quotes, single quotes, or backslashes
Index: pkgsrc/shells/bash/patches/patch-lib_malloc_malloc.c
diff -u /dev/null pkgsrc/shells/bash/patches/patch-lib_malloc_malloc.c:1.1
--- /dev/null   Tue Mar 17 17:09:48 2020
+++ pkgsrc/shells/bash/patches/patch-lib_malloc_malloc.c        Tue Mar 17 17:09:48 2020
@@ -0,0 +1,15 @@
+$NetBSD: patch-lib_malloc_malloc.c,v 1.1 2020/03/17 17:09:48 rillig Exp $
+
+Fix array subscript with char index.
+
+--- lib/malloc/malloc.c.orig   2018-06-20 13:55:09.000000000 +0000
++++ lib/malloc/malloc.c
+@@ -266,7 +266,7 @@ static const unsigned long binsizes[NBUC
+ };
+ 
+ /* binsizes[x] == (1 << ((x) + 3)) */
+-#define binsize(x)    binsizes[(x)]
++#define binsize(x)    binsizes[(size_t) (x)]
+ 
+ #if !defined (errno)
+ extern int errno;
Index: pkgsrc/shells/bash/patches/patch-subst.c
diff -u /dev/null pkgsrc/shells/bash/patches/patch-subst.c:1.1
--- /dev/null   Tue Mar 17 17:09:48 2020
+++ pkgsrc/shells/bash/patches/patch-subst.c    Tue Mar 17 17:09:48 2020
@@ -0,0 +1,15 @@
+$NetBSD: patch-subst.c,v 1.1 2020/03/17 17:09:48 rillig Exp $
+
+Fix array subscript with char index.
+
+--- subst.c.orig       2020-03-17 16:57:17.469764555 +0000
++++ subst.c
+@@ -11294,7 +11294,7 @@ shell_expand_word_list (tlist, eflags)
+                       case 'l':
+                       case 'u':
+                       case 'c':
+-                        omap[l->word->word[oind]] = 1;
++                        omap[(unsigned char) l->word->word[oind]] = 1;
+                         if (opti == 0)
+                           opts[opti++] = '-';
+                         break;



Home | Main Index | Thread Index | Old Index