]> git.pld-linux.org Git - packages/vim.git/blame - 7.2.391
- new
[packages/vim.git] / 7.2.391
CommitLineData
8587d00a
AM
1To: vim-dev@vim.org
2Subject: Patch 7.2.391
3Fcc: outbox
4From: Bram Moolenaar <Bram@moolenaar.net>
5Mime-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
8------------
9
10Patch 7.2.391
11Problem: Internal alloc(0) error when doing "CTRL-V $ c". (Martti Kuparinen)
12Solution: Fix computations in getvcol(). (partly by Lech Lorens)
13Files: src/charset.c, src/memline.c
14
15
16*** ../vim-7.2.390/src/charset.c 2009-11-03 16:03:59.000000000 +0100
17--- src/charset.c 2010-03-10 14:38:14.000000000 +0100
18***************
19*** 1255,1261 ****
20
21 vcol = 0;
22 ptr = ml_get_buf(wp->w_buffer, pos->lnum, FALSE);
23! posptr = ptr + pos->col;
24
25 /*
26 * This function is used very often, do some speed optimizations.
27--- 1255,1264 ----
28
29 vcol = 0;
30 ptr = ml_get_buf(wp->w_buffer, pos->lnum, FALSE);
31! if (pos->col == MAXCOL)
32! posptr = NULL; /* continue until the NUL */
33! else
34! posptr = ptr + pos->col;
35
36 /*
37 * This function is used very often, do some speed optimizations.
38***************
39*** 1313,1319 ****
40 incr = CHARSIZE(c);
41 }
42
43! if (ptr >= posptr) /* character at pos->col */
44 break;
45
46 vcol += incr;
47--- 1316,1322 ----
48 incr = CHARSIZE(c);
49 }
50
51! if (posptr != NULL && ptr >= posptr) /* character at pos->col */
52 break;
53
54 vcol += incr;
55***************
56*** 1334,1340 ****
57 break;
58 }
59
60! if (ptr >= posptr) /* character at pos->col */
61 break;
62
63 vcol += incr;
64--- 1337,1343 ----
65 break;
66 }
67
68! if (posptr != NULL && ptr >= posptr) /* character at pos->col */
69 break;
70
71 vcol += incr;
72*** ../vim-7.2.390/src/memline.c 2010-02-11 18:54:38.000000000 +0100
73--- src/memline.c 2010-03-10 14:38:25.000000000 +0100
74***************
75*** 2113,2124 ****
76 if (buf->b_ml.ml_mfp == NULL) /* there are no lines */
77 return (char_u *)"";
78
79! /*
80! * See if it is the same line as requested last time.
81! * Otherwise may need to flush last used line.
82! * Don't use the last used line when 'swapfile' is reset, need to load all
83! * blocks.
84! */
85 if (buf->b_ml.ml_line_lnum != lnum || mf_dont_release)
86 {
87 ml_flush_line(buf);
88--- 2113,2124 ----
89 if (buf->b_ml.ml_mfp == NULL) /* there are no lines */
90 return (char_u *)"";
91
92! /*
93! * See if it is the same line as requested last time.
94! * Otherwise may need to flush last used line.
95! * Don't use the last used line when 'swapfile' is reset, need to load all
96! * blocks.
97! */
98 if (buf->b_ml.ml_line_lnum != lnum || mf_dont_release)
99 {
100 ml_flush_line(buf);
101*** ../vim-7.2.390/src/version.c 2010-03-10 14:15:28.000000000 +0100
102--- src/version.c 2010-03-10 14:31:02.000000000 +0100
103***************
104*** 683,684 ****
105--- 683,686 ----
106 { /* Add new patch number below this line */
107+ /**/
108+ 391,
109 /**/
110
111--
112WOMAN: King of the who?
113ARTHUR: The Britons.
114WOMAN: Who are the Britons?
115ARTHUR: Well, we all are. we're all Britons and I am your king.
116 The Quest for the Holy Grail (Monty Python)
117
118 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
119/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
120\\\ download, build and distribute -- http://www.A-A-P.org ///
121 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
This page took 0.037556 seconds and 4 git commands to generate.