1 To: [email protected] |
|
2 Subject: Patch 7.2.008 |
|
3 Fcc: outbox |
|
4 From: Bram Moolenaar <[email protected]> |
|
5 Mime-Version: 1.0 |
|
6 Content-Type: text/plain; charset=ISO-8859-1 |
|
7 Content-Transfer-Encoding: 8bit |
|
8 ------------ |
|
9 |
|
10 Patch 7.2.008 |
|
11 Problem: With a BufHidden autocommand that invokes ":bunload" the window |
|
12 count for a buffer can be wrong. (Bob Hiestand) |
|
13 Solution: Don't call enter_buffer() when already in that buffer. |
|
14 Files: src/buffer.c |
|
15 |
|
16 |
|
17 *** ../vim-7.2.007/src/buffer.c Wed Aug 6 18:32:40 2008 |
|
18 --- src/buffer.c Mon Sep 1 14:25:45 2008 |
|
19 *************** |
|
20 *** 1351,1361 **** |
|
21 } |
|
22 } |
|
23 #ifdef FEAT_AUTOCMD |
|
24 # ifdef FEAT_EVAL |
|
25 ! /* An autocommand may have deleted buf or aborted the script processing! */ |
|
26 ! if (buf_valid(buf) && !aborting()) |
|
27 # else |
|
28 ! if (buf_valid(buf)) /* an autocommand may have deleted buf! */ |
|
29 # endif |
|
30 #endif |
|
31 enter_buffer(buf); |
|
32 --- 1351,1362 ---- |
|
33 } |
|
34 } |
|
35 #ifdef FEAT_AUTOCMD |
|
36 + /* An autocommand may have deleted "buf", already entered it (e.g., when |
|
37 + * it did ":bunload") or aborted the script processing! */ |
|
38 # ifdef FEAT_EVAL |
|
39 ! if (buf_valid(buf) && buf != curbuf && !aborting()) |
|
40 # else |
|
41 ! if (buf_valid(buf) && buf != curbuf) |
|
42 # endif |
|
43 #endif |
|
44 enter_buffer(buf); |
|
45 *** ../vim-7.2.007/src/version.c Mon Sep 1 16:50:09 2008 |
|
46 --- src/version.c Mon Sep 1 17:31:28 2008 |
|
47 *************** |
|
48 *** 678,679 **** |
|
49 --- 678,681 ---- |
|
50 { /* Add new patch number below this line */ |
|
51 + /**/ |
|
52 + 8, |
|
53 /**/ |
|
54 |
|
55 -- |
|
56 If Pacman had affected us as kids we'd be running around in dark rooms, |
|
57 munching pills and listening to repetitive music. |
|
58 -- Marcus Brigstocke |
|
59 |
|
60 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\ |
|
61 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ |
|
62 \\\ download, build and distribute -- http://www.A-A-P.org /// |
|
63 \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |
|