]> git.pld-linux.org Git - packages/vim.git/blob - 7.3.197
- new
[packages/vim.git] / 7.3.197
1 To: vim_dev@googlegroups.com
2 Subject: Patch 7.3.197
3 Fcc: outbox
4 From: Bram Moolenaar <Bram@moolenaar.net>
5 Mime-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8 ------------
9
10 Patch 7.3.197
11 Problem:    When a QuickfixCmdPost event removes all errors, Vim still tries
12             to jump to the first error, resulting in E42.
13 Solution:   Get the number of error after the autocmd event. (Mike Lundy)
14 Files:      src/quickfix.c
15
16
17 *** ../mercurial/vim73/src/quickfix.c   2011-05-10 16:41:13.000000000 +0200
18 --- src/quickfix.c      2011-05-19 17:34:11.000000000 +0200
19 ***************
20 *** 2813,2829 ****
21                                            (eap->cmdidx != CMD_grepadd
22                                             && eap->cmdidx != CMD_lgrepadd),
23                                            *eap->cmdlinep);
24   #ifdef FEAT_AUTOCMD
25       if (au_name != NULL)
26         apply_autocmds(EVENT_QUICKFIXCMDPOST, au_name,
27                                                curbuf->b_fname, TRUE, curbuf);
28   #endif
29       if (res > 0 && !eap->forceit)
30 -     {
31 -       if (wp != NULL)
32 -           qi = GET_LOC_LIST(wp);
33         qf_jump(qi, 0, 0, FALSE);               /* display first error */
34 -     }
35   
36       mch_remove(fname);
37       vim_free(fname);
38 --- 2813,2833 ----
39                                            (eap->cmdidx != CMD_grepadd
40                                             && eap->cmdidx != CMD_lgrepadd),
41                                            *eap->cmdlinep);
42 +     if (wp != NULL)
43 +       qi = GET_LOC_LIST(wp);
44   #ifdef FEAT_AUTOCMD
45       if (au_name != NULL)
46 +     {
47         apply_autocmds(EVENT_QUICKFIXCMDPOST, au_name,
48                                                curbuf->b_fname, TRUE, curbuf);
49 +       if (qi->qf_curlist < qi->qf_listcount)
50 +           res = qi->qf_lists[qi->qf_curlist].qf_count;
51 +       else
52 +           res = 0;
53 +     }
54   #endif
55       if (res > 0 && !eap->forceit)
56         qf_jump(qi, 0, 0, FALSE);               /* display first error */
57   
58       mch_remove(fname);
59       vim_free(fname);
60 *** ../vim-7.3.196/src/version.c        2011-05-19 17:25:36.000000000 +0200
61 --- src/version.c       2011-05-19 17:41:50.000000000 +0200
62 ***************
63 *** 711,712 ****
64 --- 711,714 ----
65   {   /* Add new patch number below this line */
66 + /**/
67 +     197,
68   /**/
69
70 -- 
71 I AM THANKFUL...
72 ...for the clothes that fit a little too snug because it
73 means I have more than enough to eat.
74
75  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
76 ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
77 \\\  an exciting new programming language -- http://www.Zimbu.org        ///
78  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
This page took 0.04208 seconds and 3 git commands to generate.