[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Can't convert control characters
From: |
Thomas Dickey |
Subject: |
Re: Can't convert control characters |
Date: |
Wed, 21 May 2003 04:48:19 -0400 |
User-agent: |
Mutt/1.2.5i |
On Wed, May 21, 2003 at 11:20:51AM +0900, Mitsuru Chinen wrote:
> Thank you for your response.
>
> Thomas Dickey <address@hidden> wrote:
> > thanks - will look. offhand, it seems that the problem is that glibc
> > treats wcslen() on 8-bit characters as an error. (I believe this is
> > a glibc bug, but am resigned to working around those).
>
> I'm afraid the cause of this bug is not in glibc.
> I found a check with using wcwidth() is wrong at line 55
> in ./ncurses/widechar/lib_cchar.c.
>
> At that line, setcchar() returns ERR when wcwidth() returns negative value.
> Because wcwidth() returns -1 when a wide character is non-printable,
> setcchar() returns ERR if control character is given.
ok (the last few occurrences of wcwidth that I fixed were for the case
when its parameter was a printable 8-bit character). At the moment it's
not clear whether "non-printable" in this sense applies to control
characters, or non-spacing characters.
--
Thomas E. Dickey <address@hidden>
http://invisible-island.net
ftp://invisible-island.net