bug-bash
[Top][All Lists]
Advanced

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

incorrect 'LC_ALL=C export LC_ALL' behavour


From: Tim Waugh
Subject: incorrect 'LC_ALL=C export LC_ALL' behavour
Date: Mon, 8 Aug 2005 12:54:15 +0100
User-agent: Mutt/1.4.2.1i

Configuration Information [Automatically generated, do not change]:
Machine: i386
OS: linux-gnu
Compiler: i386-redhat-linux-gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='i386' 
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i386-redhat-linux-gnu' 
-DCONF_VENDOR='redhat' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL 
-DHAVE_CONFIG_H  -I.  -I. -I./include -I./lib  -D_GNU_SOURCE 
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 
-fexceptions -m32 -march=i386 -mtune=pentium4 -fasynchronous-unwind-tables
uname output: Linux gene.surrey.redhat.com 2.6.12-1.1432_FC5 #1 Wed Jul 13 
03:12:36 EDT 2005 i686 i686 i386 GNU/Linux
Machine Type: i386-redhat-linux-gnu

Bash Version: 3.0
Patch Level: 16
Release Status: release

Description:
        See:
        https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=165249

        This script gives incorrect output when run against correct
        locale data:

rm -rf arena
mkdir arena
cd arena
touch a B c
LC_ALL=en_US.UTF-8
LC_ALL=C export LC_ALL
echo [a-c]

        The expected output is 'a c', but the actual output includes
        'B'.  Although the LC_ALL variable has been set, the
        setlocale() function was not called to update the locale.

Repeat-By:
        See above.

Fix:

--- bash-3.0/builtins/setattr.def.setlocale     2005-08-08 12:22:42.000000000 
+0100
+++ bash-3.0/builtins/setattr.def       2005-08-08 12:25:16.000000000 +0100
@@ -423,4 +423,7 @@
 
   if (var && (exported_p (var) || (attribute & att_exported)))
     array_needs_making++;      /* XXX */
+
+  if (var)
+    stupidly_hack_special_variables (name);
 }




reply via email to

[Prev in Thread] Current Thread [Next in Thread]