Eval ${#name[subscript]} incorrect when having multibyte characters.

2008-07-06 Thread Wang Xin
Configuration Information [Automatically generated, do not change]: Machine: i686 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='i686' -DCONF_OSTYPE='linu x-gnu' -DCONF_MACHTYPE='i686-pc-linux-gnu' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/ local/share/locale' -DPACKA

Re: stty sometimes hangs (ERESTARTSYS error) when called from .bashrc (cause discovered)

2008-07-06 Thread Joe Peterson
I have done more investigation, and I now know the cause of the bash/stty problem. It appears to be a race condition in bash (well, between two different bash shells, actually). I saw a post from a while back about something similar by Ingo Molnar, so I have copied him here too. Here is the ps t