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: ":windo g/pattern/q" closes windows and reports "N more lines".
13 Solution: Remember what buffer ":global" started in. (Jean-Rene David)
17 *** ../vim-7.3.184/src/ex_cmds.c 2011-04-11 21:35:03.000000000 +0200
18 --- src/ex_cmds.c 2011-05-10 15:58:48.000000000 +0200
24 ! linenr_T old_lcount; /* b_ml.ml_line_count before the command */
25 ! linenr_T lnum; /* line number according to old situation */
28 * Set current position only once for a global command.
33 ! linenr_T old_lcount; /* b_ml.ml_line_count before the command */
34 ! buf_T *old_buf = curbuf; /* remember what buffer we started in */
35 ! linenr_T lnum; /* line number according to old situation */
38 * Set current position only once for a global command.
43 /* If substitutes done, report number of substitutes, otherwise report
44 ! * number of extra or deleted lines. */
45 ! if (!do_sub_msg(FALSE))
46 msgmore(curbuf->b_ml.ml_line_count - old_lcount);
52 /* If substitutes done, report number of substitutes, otherwise report
53 ! * number of extra or deleted lines.
54 ! * Don't report extra or deleted lines in the edge case where the buffer
55 ! * we are in after execution is different from the buffer we started in. */
56 ! if (!do_sub_msg(FALSE) && curbuf == old_buf)
57 msgmore(curbuf->b_ml.ml_line_count - old_lcount);
60 *** ../vim-7.3.184/src/version.c 2011-05-10 15:52:10.000000000 +0200
61 --- src/version.c 2011-05-10 15:57:40.000000000 +0200
65 { /* Add new patch number below this line */
71 hundred-and-one symptoms of being an internet addict:
72 79. All of your most erotic dreams have a scrollbar at the right side.
74 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
75 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
76 \\\ an exciting new programming language -- http://www.Zimbu.org ///
77 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///