On Sat, Jul 16, 2005 at 12:44:34PM +0200, Bram Moolenaar wrote:
> Hye-Shik Chang wrote:
> > The current version of vim doesn't handle non-utf8 multibyte encodings
> > such as EUC and/or GBK in FreeBSD. Cursor moves around weird places
> > inside a character and the last character on each lines disappears
> > sometimes.
> The behavior of mblen() on various systems has always been a bit unclear
> to me. Your remark makes a lot of sense, but I wonder why nobody had
> this problem before.
In fact, many of Japanese FreeBSD users seems to have been suffered
from the problem:
(even if you can't read japanese, you still can discover some
alphabets on the page. :)
I didn't aware of the problem because I'm using UTF-8 locale, but
few friends of mine asked a help to me.
> I'll include this now in Vim 7 and await further comments. Hopefully
> there is no mblen() implementation that crashes when invoked with a NULL
Thanks for applying the fix! I think the fix will not harm any
platform. mblen(NULL, 0); is clearly defined in POSIX as a reset