File: bash53-006.diff

package info (click to toggle)
bash 5.3-2
  • links: PTS
  • area: main
  • in suites: sid
  • size: 44,432 kB
  • sloc: ansic: 134,747; sh: 8,866; yacc: 5,966; makefile: 4,697; perl: 4,105; asm: 48; awk: 23; sed: 16
file content (37 lines) | stat: -rw-r--r-- 1,085 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
			     BASH PATCH REPORT
			     =================

Bash-Release:	5.3
Patch-ID:	bash53-006

Bug-Reported-by:	Duncan Roe <duncan_roe@optusnet.com.au>
Bug-Reference-ID:	<aL0p/3BQeCLc6krz@dimstar.local.net>
Bug-Reference-URL:	https://lists.gnu.org/archive/html/bug-bash/2025-09/msg00053.html

Bug-Description:

When `globasciiranges' is enabled, glob patterns with ranges in bracket
expressions can produce incorrect matches for character ranges whose
start and end are non-ascii characters.

--- a/lib/glob/smatch.c
+++ b/lib/glob/smatch.c
@@ -390,7 +390,7 @@ charcmp_wc (wint_t c1, wint_t c2, int fo
   if (c1 == c2)
     return 0;
 
-  if (forcecoll == 0 && glob_asciirange && c1 <= UCHAR_MAX && c2 <= UCHAR_MAX)
+  if (forcecoll == 0 && glob_asciirange)
     return ((int)(c1 - c2));
 
   s1[0] = c1;
--- 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_ */