4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
11 Problem: ':echo "\xf7"' displays the illegal byte as if it was a character
12 and leaves "cho" after it.
13 Solution: When checking the length of a UTF-8 byte sequence and it's shorter
14 than the number of bytes available, assume it's an illegal byte.
18 *** ../vim-6.2.243/src/mbyte.c Sun Jan 11 12:45:02 2004
19 --- src/mbyte.c Sun Feb 8 15:12:29 2004
24 len = utf8len_tab[*p];
25 ! for (i = 1; i < len && i < size; ++i)
26 if ((p[i] & 0xc0) != 0x80)
32 len = utf8len_tab[*p];
34 ! return 1; /* Probably illegal byte sequence. */
35 ! for (i = 1; i < len; ++i)
36 if ((p[i] & 0xc0) != 0x80)
39 *** ../vim-6.2.243/src/version.c Sun Feb 8 14:41:05 2004
40 --- src/version.c Sun Feb 8 15:10:55 2004
44 { /* Add new patch number below this line */
50 hundred-and-one symptoms of being an internet addict:
51 84. Books in your bookcase bear the names Bongo, WinSock and Inside OLE
53 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
54 /// Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
55 \\\ Project leader for A-A-P -- http://www.A-A-P.org ///
56 \\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html ///