4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
11 Problem: Memory leaks when out of memory.
12 Solution: Free the memory.
13 Files: src/edit.c, src/diff.c
16 *** ../vim-7.0.199/src/edit.c Tue Feb 20 03:33:51 2007
17 --- src/edit.c Fri Feb 16 01:15:49 2007
24 + regmatch.regprog = NULL; /* so that we can goto theend */
26 /* If 'infercase' is set, don't use 'smartcase' here */
30 char_u *pat_esc = vim_strsave_escaped(pat, (char_u *)"\\");
34 i = (int)STRLEN(pat_esc) + 10;
41 vim_snprintf((char *)ptr, i, "^\\s*\\zs\\V%s", pat_esc);
42 regmatch.regprog = vim_regcomp(ptr, RE_MAGIC);
44 char_u *pat_esc = vim_strsave_escaped(pat, (char_u *)"\\");
48 i = (int)STRLEN(pat_esc) + 10;
55 vim_snprintf((char *)ptr, i, "^\\s*\\zs\\V%s", pat_esc);
56 regmatch.regprog = vim_regcomp(ptr, RE_MAGIC);
57 *** ../vim-7.0.199/src/diff.c Sun Apr 23 00:23:34 2006
58 --- src/diff.c Fri Feb 16 01:18:41 2007
63 idx = diff_buf_idx(wp->w_buffer);
64 if (idx == DB_COUNT) /* cannot happen */
70 /* search for a change that includes "lnum" in the list of diffblocks. */
71 for (dp = curtab->tp_first_diff; dp != NULL; dp = dp->df_next)
72 if (lnum <= dp->df_lnum[idx] + dp->df_count[idx])
74 if (dp == NULL || diff_check_sanity(curtab, dp) == FAIL)
80 off = lnum - dp->df_lnum[idx];
82 *** ../vim-7.0.199/src/version.c Tue Feb 20 03:33:51 2007
83 --- src/version.c Tue Feb 20 03:48:16 2007
87 { /* Add new patch number below this line */
93 hundred-and-one symptoms of being an internet addict:
94 157. You fum through a magazine, you first check to see if it has a web
97 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
98 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
99 \\\ download, build and distribute -- http://www.A-A-P.org ///
100 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///