Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Directories with multibyte names are never empty



2008/6/4 Raúl Núñez de Arenas Coronado <raul@xxxxxxxxxxxx>:
> Hi all :)
>
> First of all, my excuses if this is already solved. I haven't been
> following the list with much attention lately and I'm using zsh-4.3.4
> in my Ubuntu, which may be a bit outdated.
>
> This said, the problem is very easy to reproduce:
>
> $ mkdir H
> $ mkdir H/ō  <-- This is an "o" with a dash above
> $ mkdir H/a
> $ mkdir H/empty
> $ touch H/a/test
> $ touch H/ō/test
> $ print -l **/*(/^F)
> H/empty
> H/ō
>
> The last output should be just "H/empty", but the directory with the
> "ō" is considered empty, too (and it is obviously not empty).
>
> I have multibyte enabled and my encoding is UTF-8 (both in console and
> in the filesystem). Curiously, this doesn't happen with letters like
> "ñ", "á", "é", etc. which are multibyte and are encoded using two
> bytes in UTF-8, just like "ō" (0x014D => 0xC5 0x8D in UTF-8).
>
> My locale is a mix between en_US-UTF-8 and es_ES-UTF-8 (I want the
> messages in English; date, time, collation and ctype in Spanish).
>
> If you need more information, just tell. Thanks a lot in advance :)

FWIW, it works fine here, 4.3.6-dev-0.

-- 
Mikael Magnusson


Messages sorted by: Reverse Date, Date, Thread, Author