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: Crash in autocomplete. (Greg Weber)
12 Solution: Check not going over allocated buffer size.
16 *** ../vim-7.3.370/src/misc2.c 2011-10-26 11:40:56.000000000 +0200
17 --- src/misc2.c 2011-12-08 17:49:23.000000000 +0100
21 static int ff_path_in_stoplist __ARGS((char_u *, int, char_u **));
24 + static char_u e_pathtoolong[] = N_("E854: path too long for completion");
28 * if someone likes findfirst/findnext, here are the functions
33 while (*wc_part != NUL)
35 + if (len + 5 >= MAXPATHL)
37 + EMSG(_(e_pathtoolong));
40 if (STRNCMP(wc_part, "**", 2) == 0)
42 ff_expand_buffer[len++] = *wc_part++;
48 /* create an absolute path */
49 + if (STRLEN(search_ctx->ffsc_start_dir)
50 + + STRLEN(search_ctx->ffsc_fix_path) + 3 >= MAXPATHL)
52 + EMSG(_(e_pathtoolong));
55 STRCPY(ff_expand_buffer, search_ctx->ffsc_start_dir);
56 add_pathsep(ff_expand_buffer);
57 STRCAT(ff_expand_buffer, search_ctx->ffsc_fix_path);
58 *** ../vim-7.3.370/src/version.c 2011-12-08 16:00:12.000000000 +0100
59 --- src/version.c 2011-12-08 17:46:41.000000000 +0100
63 { /* Add new patch number below this line */
69 hundred-and-one symptoms of being an internet addict:
70 253. You wait for a slow loading web page before going to the toilet.
72 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
73 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
74 \\\ an exciting new programming language -- http://www.Zimbu.org ///
75 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///