1 To: [email protected] |
|
2 Subject: Patch 7.2.243 |
|
3 Fcc: outbox |
|
4 From: Bram Moolenaar <[email protected]> |
|
5 Mime-Version: 1.0 |
|
6 Content-Type: text/plain; charset=UTF-8 |
|
7 Content-Transfer-Encoding: 8bit |
|
8 ------------ |
|
9 |
|
10 Patch 7.2.243 |
|
11 Problem: Memory leak when using :vimgrep and resizing. (Dominique Pelle) |
|
12 Solution: Free memory for aucmd_win when resizing and don't allocate it |
|
13 twice. |
|
14 Files: src/screen.c |
|
15 |
|
16 |
|
17 *** ../vim-7.2.242/src/screen.c 2009-06-16 17:22:38.000000000 +0200 |
|
18 --- src/screen.c 2009-07-29 15:59:37.000000000 +0200 |
|
19 *************** |
|
20 *** 7467,7472 **** |
|
21 --- 7467,7476 ---- |
|
22 */ |
|
23 FOR_ALL_TAB_WINDOWS(tp, wp) |
|
24 win_free_lsize(wp); |
|
25 + #ifdef FEAT_AUTOCMD |
|
26 + if (aucmd_win != NULL) |
|
27 + win_free_lsize(aucmd_win); |
|
28 + #endif |
|
29 |
|
30 new_ScreenLines = (schar_T *)lalloc((long_u)( |
|
31 (Rows + 1) * Columns * sizeof(schar_T)), FALSE); |
|
32 *************** |
|
33 *** 7504,7510 **** |
|
34 } |
|
35 } |
|
36 #ifdef FEAT_AUTOCMD |
|
37 ! if (aucmd_win != NULL && win_alloc_lines(aucmd_win) == FAIL) |
|
38 outofmem = TRUE; |
|
39 #endif |
|
40 #ifdef FEAT_WINDOWS |
|
41 --- 7508,7515 ---- |
|
42 } |
|
43 } |
|
44 #ifdef FEAT_AUTOCMD |
|
45 ! if (aucmd_win != NULL && aucmd_win->w_lines == NULL |
|
46 ! && win_alloc_lines(aucmd_win) == FAIL) |
|
47 outofmem = TRUE; |
|
48 #endif |
|
49 #ifdef FEAT_WINDOWS |
|
50 *** ../vim-7.2.242/src/version.c 2009-07-29 15:41:32.000000000 +0200 |
|
51 --- src/version.c 2009-07-29 16:07:47.000000000 +0200 |
|
52 *************** |
|
53 *** 678,679 **** |
|
54 --- 678,681 ---- |
|
55 { /* Add new patch number below this line */ |
|
56 + /**/ |
|
57 + 243, |
|
58 /**/ |
|
59 |
|
60 -- |
|
61 hundred-and-one symptoms of being an internet addict: |
|
62 118. You are on a first-name basis with your ISP's staff. |
|
63 |
|
64 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\ |
|
65 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ |
|
66 \\\ download, build and distribute -- http://www.A-A-P.org /// |
|
67 \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |
|