1 To: vim_dev@googlegroups.com
4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
11 Problem: Using "z=" on a multi-byte character may cause a crash.
12 Solution: Don't use strlen() on an int pointer.
16 *** ../vim-7.3.520/src/spell.c 2012-01-10 22:26:12.000000000 +0100
17 --- src/spell.c 2012-05-18 18:01:58.000000000 +0200
22 int did_white = FALSE;
25 * Convert the multi-byte string to a wide-character string.
26 * Remove accents, if wanted. We actually remove all non-word characters.
27 * But keep white space.
30 for (s = inword; *s != NUL; )
36 int did_white = FALSE;
41 * Convert the multi-byte string to a wide-character string.
42 * Remove accents, if wanted. We actually remove all non-word characters.
43 * But keep white space.
46 for (s = inword; *s != NUL; )
59 ! * This comes from Aspell phonet.cpp.
60 * Converted from C++ to C. Added support for multi-byte chars.
61 * Changed to keep spaces.
67 ! word[wordlen++] = c;
69 ! word[wordlen] = NUL;
72 ! * This algorithm comes from Aspell phonet.cpp.
73 * Converted from C++ to C. Added support for multi-byte chars.
74 * Changed to keep spaces.
80 mch_memmove(word + i + k0, word + i + k,
81 ! sizeof(int) * (STRLEN(word + i + k) + 1));
83 /* new "actual letter" */
88 mch_memmove(word + i + k0, word + i + k,
89 ! sizeof(int) * (wordlen - (i + k) + 1));
91 /* new "actual letter" */
97 mch_memmove(word, word + i + 1,
98 ! sizeof(int) * (STRLEN(word + i + 1) + 1));
105 mch_memmove(word, word + i + 1,
106 ! sizeof(int) * (wordlen - (i + 1) + 1));
110 *** ../vim-7.3.520/src/version.c 2012-05-18 17:03:14.000000000 +0200
111 --- src/version.c 2012-05-18 18:06:29.000000000 +0200
115 { /* Add new patch number below this line */
121 OLD WOMAN: King of the WHO?
123 OLD WOMAN: Who are the Britons?
124 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
126 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
127 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
128 \\\ an exciting new programming language -- http://www.Zimbu.org ///
129 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///